Previously, this feature was in beta in Gmail's "Labs" section. Now, it's open to personal accounts on desktop (not yet available on tablets or smartphones).
Want to make sure you have the ability to unsend emails in Gmail? Here's what you need to do.
How to Unsend Emails in Gmail
1) First, you need to check that you have "Undo Send" enabled. From your inbox, choose the gear icon in the top right-hand corner, and select "Settings."
2) Scroll down to the "Undo Send" section, and click "Enable." You also will need to choose how long you will have to cancel an email (either 5, 10, 20, or 30 seconds). When you're done, click "Save Changes" to enable this new feature.
3) The next time you send an email, a thin yellow line will appear at the top of your screen -- this is where you have a chance to "Undo" your send. Click "Undo" to stop the message from sending.
Note: After you leave the screen on which your email was sent, you no longer have the option to undo it.
4) Thanks to the "Undo Send" feature, you'll never make an email mistake again.