The elytra act as protective wing-cases for the hind wings underneath, which are used for flying. To fly, a beetle opens the elytra and then extends the hindwings, flying while still holding the elytra open, though some beetles in the families Scarabaeidae and Buprestidae can fly with the elytra closed.