There are a few different ways.
According to Google themselves, you can:
Use backup options
- If you've lost access to your primary phone, you can select to have codes sent to backup phones. In addition, you can use one of your printable backup codes to sign in.
Sign in from a trusted computer
- If you’ve previously signed in from a computer and checked that the computer should remember you, you might be able to sign in from that computer without a verification code. Once you’re in your account, you can turn off 2-Step Verification until you can again get verification codes.
Get a new phone from your carrier
- If you’ve lost your phone, you might be able to buy a new phone with the same phone number from your carrier or purchase a new SIM card.
Or if all else fails, you can Fill out our Account Recovery form.
More details here: https://support.google.com/accounts/answer/185834?hl=en