Hide Zero Values in a Word Mail Merge with an IF Field
Question details
Hide zero values in a Word mail merge while displaying other merged values.
- Product
- Microsoft Word Mail Merge
- Device & OS
- not provided
- Scenario
- A Word mail merge uses an Excel data source that may contain numeric values, text, or formulas returning blanks.
- Observed behavior
- The merge displays MERGEFIELD text or an unexpected value such as 2.00, and results are inconsistent across fields or rows.
Open the Word mail merge main document and its Excel data source. Identify the exact merge field name and check whether its Excel column contains numbers, text, or formulas that return blanks.
Use a Nested IF Field to Hide Zero Values
Use this method when Word should display a blank for a merged zero and show other values.
Word field braces must be inserted as field characters, not typed as ordinary braces. The comparison can also be affected by how Word reads values from Excel.
In the Word merge document, click where the value should appear and press Ctrl+F9 to insert an empty pair of field braces.
Inside the braces, create the expression { IF { MERGEFIELD fieldname } = "0" "" "{ MERGEFIELD fieldname }" }. Replace both instances of fieldname with the exact data-source column name, and use Ctrl+F9 to insert each nested MERGEFIELD brace pair.
Press Ctrl+A, then F9 to update the fields in the main document. On the Mailings tab, select Preview Results and move through several records to check zeros, blanks, and nonzero values.
If Word shows field codes instead of results, press Alt+F9 to toggle the field-code display. If MERGEFIELD appears as literal text, rebuild its braces with Ctrl+F9 and update the field again.
Prepare a Consistent Merge Column in Excel
Use a helper column when formula blanks, text, or differently formatted zeros produce inconsistent merge results.
Work with Mail Merge Documents in WPS Office
WPS Office is a free, lightweight alternative for working with documents and spreadsheets in a familiar interface. Its format support can help you move existing Office files into WPS, although it does not fix a Word-specific field or data connection issue.

Frequently Asked Questions
Why does Word show MERGEFIELD instead of the merged value?
Field codes may be visible, or the braces may have been typed as ordinary characters. Press Alt+F9 to toggle field-code display. If the text is still literal, insert the field braces with Ctrl+F9 and update the field with F9.
Why does the IF field work for some rows but not others?
The Excel column may contain a mixture of numbers, text, and formulas returning blanks. Check the affected rows in Excel and use Mailings > Preview Results in Word to see how each value is interpreted.
Can I hide zeros without hiding text values?
Yes. Use an IF field that returns an empty string for zero and the MERGEFIELD result otherwise. If the source contains inconsistent value types, prepare a helper column in Excel and preview both text and zero records.
What should I check if a blank Excel formula result appears as zero?
Check the formula result and the affected record in Word's Mailings > Preview Results. If the connection passes the blank as zero, use an IF field to suppress that zero and test other records to make sure their values still appear.




