How to Fix Documents Opening as Code in WordPad
Question details
Users are trying to open a document or image file using WordPad, but the content fails to render properly and displays as unreadable code or gibberish symbols.

- Product
- WordPad
- Device & OS
- Windows
- Scenario
- Attempting to open complex document files or image files using the default Windows WordPad application.
- Observed behavior
- The application fails to render the file correctly, displaying raw binary data as plain text, which looks like random characters, symbols, or code.
Check the file extension (such as .docx, .pdf, or .jpg) to confirm the exact type of file you are dealing with before selecting the appropriate program to open it.
Open the Document with Microsoft Word or a Compatible Alternative
WordPad is a basic text editor and lacks support for advanced Microsoft Office document formats, which causes complex files to display as code.
When you attempt to open a complex document like a .docx file or a PDF in WordPad, the software tries to read the file's raw binary data as plain text. This results in a display of gibberish code.
To view the document's contents and formatting accurately, you must use a dedicated word processor designed to decode these specific formats.
Locate the document that is displaying as code, right-click on it to open the context menu.
Hover your mouse over the "Open with" option to view a list of available applications.
Select "Microsoft Word", "WPS Office", or another dedicated word processor from the list. If your preferred app isn't listed, click "Choose another app" to find it.

Use a Dedicated Image Viewer for Picture Files
Image files will display as raw code if forced to open within a text editor like WordPad.
Effortlessly Open Any Document Format with WPS Office
If WordPad cannot properly display your files, WPS Office provides a free, lightweight, and robust solution. It handles a wide range of file types perfectly, ensuring your documents never appear as scrambled code.
- 1. Install WPS Office: Download and install WPS Office on your computer.
- 2. Locate the affected file: Find the document file that previously opened as code in WordPad.
- 3. Open with WPS: Right-click the file, select "Open with", and choose "WPS Office" from the list of programs.
- 4. View your document: View and edit your document normally with all its original formatting intact.

Frequently Asked Questions
Does WordPad support Microsoft Word (.docx) files?
WordPad provides very limited support for .docx files. While it can open basic text from some Word documents, complex formatting, tables, or macros will not render properly and may cause the file to display as unreadable code.
Why do images show up as random symbols in WordPad?
WordPad is primarily a text editor. If you attempt to open an image file directly into the program, WordPad reads the image's binary data as plain text characters, resulting in a screen full of random symbols. You must use an image viewer to open pictures.
How do I stop my documents from automatically opening in WordPad?
Right-click a document of the specific format you want to change, select "Open with" and then click "Choose another app". Select your preferred word processor, check the "Always use this app to open" box, and click OK to change your default program.
What file formats are officially supported by WordPad?
WordPad natively supports Rich Text Format (.rtf), plain text (.txt), Windows Write (.wri), and OpenDocument Text (.odt). It has only basic reading capabilities for older Word formats depending on your specific version of Windows.




