Extract Text Between Characters in Excel — Brackets, Quotes & More | SheetMaster
Free formula generator
Open MID formula generatorExtracting text that appears between two specific characters (like brackets, parentheses, or custom delimiters) is a common parsing task. Here's how to do it in Excel.
Extract Text Between Two Identical Characters
To extract text between two asterisks in "Order *ABC123* confirmed":
=MID(A2, FIND("*",A2)+1, FIND("*",A2,FIND("*",A2)+1)-FIND("*",A2)-1)
Extract Text Between Parentheses ( )
=MID(A2, FIND("(",A2)+1, FIND(")",A2)-FIND("(",A2)-1)
Example: "Product (XYZ-001) Available" → "XYZ-001"
Extract Text Between Square Brackets [ ]
=MID(A2, FIND("[",A2)+1, FIND("]",A2)-FIND("[",A2)-1)
Extract Text Between Two Different Characters
To extract text between "<" and ">" (HTML-style tags):
=MID(A2, FIND("<",A2)+1, FIND(">",A2)-FIND("<",A2)-1)
Handle Missing Delimiters with IFERROR
=IFERROR(MID(A2, FIND("(",A2)+1, FIND(")",A2)-FIND("(",A2)-1), "")
Returns blank if the delimiter isn't found, preventing ugly #VALUE! errors.
Excel 365: TEXTBEFORE and TEXTAFTER (Cleaner)
=TEXTBEFORE(TEXTAFTER(A2,"("),")")
Much more readable — TEXTAFTER extracts after "(", then TEXTBEFORE cuts before ")".
FAQ
How do I extract text between two characters in Excel?
Use =MID(A2, FIND(char1,A2)+1, FIND(char2,A2)-FIND(char1,A2)-1)
What if there are multiple occurrences of the delimiter?
FIND returns the first occurrence. Use FIND with a start position argument to find the second: FIND(char, A2, FIND(char,A2)+1)
Is there an easier way in Excel 365?
Yes: =TEXTBEFORE(TEXTAFTER(A2, open_char), close_char)
Related: Extract Last Name from Full Name and Extract Domain from Email.
📋 Related Formula Tools
Want to generate the formula directly? Try our free formula generators:
📬 Get Weekly Excel Tips
Join thousands of Excel users who receive our weekly formula tips, tricks, and productivity hacks.
Subscribe Free →📖 Continue Reading
How to Get First Word from Cell in Excel (3 Formulas Compared)
Learn 3 Excel formulas to extract the first word from a cell — LEFT+FIND for all versions, TEXTBEFORE for Excel 365. Step-by-step with examples.
How to Calculate Percentage Increase in Excel — Formula & Examples | SheetMaster
Master the Excel percentage increase formula in under 2 minutes. Step-by-step with real examples for sales growth, revenue tracking & YoY comparisons. Copy the formula, done.
Excel Formula to Find Duplicates in Two Columns (Step-by-Step)
Find duplicate values across two columns in Excel using COUNTIF, VLOOKUP, and conditional formatting. Includes formulas to highlight and extract duplicates.
Calculate Business Days Between Two Dates in Excel (NETWORKDAYS)
Use the NETWORKDAYS and NETWORKDAYS.INTL functions to calculate the number of business days between two dates in Excel. Includes examples and holiday handling.