How to Use the MID Function in Excel (Extract Text from the Middle) The MID() function in Excel helps you extract a substring from the middle of a text string, based on a starting position and the number of characters you want to retrieve. 📘 Syntax: =MID(text, start_num, num_chars) ✅ Example: =MID("HR2025EMP", 3, 4) This returns "2025" , which might represent a joining year or code. 🎯 Use Cases: Extract IDs or year from structured codes Retrieve names, titles, or codes hidden in strings Handle formats like "ABC-123-XYZ" easily 💡 Bonus Tip: Combine FIND() with MID() for dynamic text extraction when positions vary. Keep learning with ScriptDataInsights for more Excel skills!