Document Editing Problems

Hide Zero Values in a Word Mail Merge with an IF Field

John WilsonJohn Wilson Nov 14, 2026 868 views

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.
Before you start

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.

Solution 1Recommended

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.

1
Insert the outer field

In the Word merge document, click where the value should appear and press Ctrl+F9 to insert an empty pair of field braces.

2
Build the IF expression

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.

3
Update and preview

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.

4
Check displayed field codes

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.

Check the imported value: A source value may arrive as text or in a form such as 0.00 rather than 0. Check the affected records in Preview Results; if the comparison is inconsistent, use a helper column in Excel.
Free Microsoft Office alternative

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.

Work with Microsoft Word DOCX documents and Excel XLSX spreadsheets.Use a familiar interface to edit documents and prepare spreadsheet data.Keep mail merge documents and their source data together in one office suite.Use free core editing tools in a lightweight office suite.
microsoft office alternative - wps office

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.