Tip: Other languages are Google-Translated. You can visit the English version of this link.
Log in


How to extract state, zip code or city from address in Excel?

For extracting state, zip code or city from address cell to individual cells, what would you do? With this article, we will show you formulas to deal with this problem. Please browse for more details.

Extract state, zip code or city from address in Excel

Extract state from address

Extract zip code from address

Extract city from address

Easily extract email domain from email address in Excel

With Kutools for Excel's Extract Text utility (click Kutools > Text > Extract Text), you can easily extract email domain from email address or extract text between two symbols from cells in Excel. See screenshot:

Kutools for Excel includes more than 300 handy Excel tools. Free to try with no limitation in 60 days. Download the free trial now

Extract state, zip code or city from address in Excel

Supposing the address locates in cell A2, please do as follows step by step to extract state, zip code or city from address in Excel.

Extract state from address

1. Select a blank cell to place the extracted state. Here I select cell B2.

2. Copy and paste formula =MID(SUBSTITUTE(A2," ",""), FIND(",",SUBSTITUTE(A2," ",""))+8,2) into the Formula Bar, and then press the Enter key.

Then you will get the State in the selected cell.


1. In the formula, A2 is the cell which locates the full address;

2. The number 8 is the eighth character as well as the first character of the state after the first comma of the address;

3. The number 2 means that the state in this address just includes two characters. You can change the numbers based on your own address.

Extract zip code from address

1. Select a blank cell, copy and paste formula =MID(SUBSTITUTE(A2," ",""), FIND(",",SUBSTITUTE(A2," ",""))+10,5) into the Formula Bar and press the Enter key.

Note: As the above notes mentioned, the number 10 in the formula is the tenth character after the first comma; and the number 5 means that there are five numbers constitute the zip code.

Please click How to extract postcode from address list in Excel? for more details of extract zip code from address.

Extract city from address

For extracting the city from address, just change the last two numbers of the above formula to =MID(SUBSTITUTE(A2," ",""), FIND(",",SUBSTITUTE(A2," ",""))+1,6).

Related Article:

Recommended Productivity Tools

Ribbon of Excel (with Kutools for Excel installed)

300+ Advanced Features Increase Your Productivity by 71%, and Help You To Stand Out From Crowd!

Would you like to complete your daily work quickly and perfectly? Kutools For Excel brings 300+ cool and powerful advanced features (Combine workbooks, sum by color, split cell contents, convert date, and so on...) for 1500+ work scenarios, helps you solve 82% Excel problems.

  •  Deal with all complicated tasks in seconds, help to enhance your work ability, get success from the fierce competition, and never worry about being fired.
  •  Save a lot of work time, leave much time for you to love and care the family and enjoy a comfortable life now.
  •  Reduce thousands of keyboard and mouse clicks every day, relieve your tired eyes and hands, and give you a healthy body.
  •  Become an Excel expert in 3 minutes, and get admiring glance from your colleagues or friends.
  •  No longer need to remember any painful formulas and VBA codes, have a relaxing and pleasant mind, give you a thrill you've never had before.
  •  Spend only $39, but worth than $4000 training of others. Being used by 110,000 elites and 300+ well-known companies.
  •  60-day unlimited free trial. 60-day money back guarantee. Free upgrade and support for 2 years. Buy once, use forever.
  •  Change the way you work now, and give you a better life immediately!

Office Tab Brings Efficient And Handy Tabs to Office (include Excel), Just Like Chrome, Firefox, And New IE

  • Increases your productivity by 50% when viewing and editing multiple documents.
  • Reduce hundreds of mouse clicks for you every day, say goodbye to mouse hand.
  • Open and create documents in new tabs of same window, rather than in new windows.
  • Help you work faster and easily stand out from the crowd! One second to switch between dozens of open documents!
Say something here...
symbols left.
You are guest ( Sign Up? )
or post as a guest, but your post won't be published automatically.
Loading comment... The comment will be refreshed after 00:00.

Be the first to comment.