Skip to content
Free Excel Tutorials
  • Home
  • Excel For Beginners
  • Excel Intermediate
  • Advanced Excel For Experts

Data Analysis

  • What-If Analysis: Scenarios and Goal Seek in Excel
  • Remove Duplicates Example in Excel
  • How To Filter Data in Excel
  • Excel Frequency Function Example
  • How to Create Column Chart in Excel

References

  • How to create dynamic named range with OFFSET in Excel
  • How to use Excel ROW Function
  • How to use Excel VLOOKUP Function
  • INDEX function: Description, Usage, Syntax, Examples and Explanation
  • How to get address of first cell in range in Excel

Data Validations

  • Excel Data validation must not contain
  • Excel Data validation only dates between
  • Excel Data validation must begin with
  • Excel Data validation number multiple 100
  • Excel Data validation exists in list

How to strip html from text or numbers in Excel

by

To strip html or other markup from values in cells, you can use the MID function.

Formula

=MID(text,start,LEN(text)-markup_len)

Explanation

In the example shown, the formula in C5 is:

=MID(B5,4,LEN(B5)-7)

How this formula works

The MID function returns characters using a fixed starting point and ending point. In this case, the markup consists of the html bold tag, which appears at the start of each cell and the associated closing tag, which appears at the end.

The MID function has been configured to always start at 4, which effectively strips the starting tag from the value. The second argument, num_chars, is calculated by getting the total characters in the cell with LEN, then subtracting 7. We use 7 because the starting bold tag is 3 characters and the closing tag is 4 characters = 7 characters total.

With these arguments, MID extracts just the text between the two tags and returns the result.

Post navigation

Next Post:

Create One-dimensional and Two-dimensional Array

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Learn Basic Excel

Ribbon
Workbook
Worksheets
Format Cells
Find & Select
Sort & Filter
Templates
Print
Share
Protect
Keyboard Shortcuts

Categories

  • Charts
  • Data Analysis
  • Data Validation
  • Excel Functions
    • Cube Functions
    • Database Functions
    • Date and Time Functions
    • Engineering Functions
    • Financial Functions
    • Information Functions
    • Logical Functions
    • Lookup and Reference Functions
    • Math and Trig Functions
    • Statistical Functions
    • Text Functions
    • Web Functions
  • Excel VBA
  • Excel Video Tutorials
  • Formatting
  • Grouping
  • Others

Logical Functions

  • How to use Excel NOT Function
  • Check multiple cells are equal in Excel
  • How to use Excel FALSE Function
  • How to use Excel TRUE Function
  • IFS function: Description, Usage, Syntax, Examples and Explanation

Date Time

  • NETWORKDAYS.INTL function: Description, Usage, Syntax, Examples and Explanation
  • Count holidays between two dates in Excel
  • Get fiscal quarter from date in Excel
  • Calculate expiration date in Excel
  • How to get same date next year or previous year in Excel

Grouping

  • Categorize text with keywords in Excel
  • Group times into unequal buckets in Excel
  • How to randomly assign data to groups in Excel
  • Group arbitrary text values in Excel
  • Calculate conditional mode with criteria in Excel

General

  • Flash Fill in Excel
  • Subtotal by color in Excel
  • How to choose page/paper size in Excel before Printing
  • Share Excel data with Word documents
  • How to test a range for numbers in Excel
© 2025 xlsoffice . All Right Reserved. | Teal Smiles | Abbreviations And Their Meaning