Formula Library

Excel Formula To Grab Text Before An Underscore In A Text String

Grab text before an underscore a text string with a ready-to-use formula for Excel, Google Sheets, and WPS.

Quick answer

Grab text before an underscore a text string.

Unified formula

ExcelWPS
=TEXTBEFORE(A2, "_")
View platform differences

Google Sheets

=INDEX(SPLIT(A2, "_"), 1)

How it works

Need a custom version?

Related formulas