.REG Windows Registry
.reg

Windows Registry

A REG file is a plain-text script containing Windows Registry entries. When executed, it merges keys and values into the registry. FileDex does not convert REG files but provides format reference information.

بنية الصيغة
Header magic bytes
Sections code · data
Text FormatWindows RegistryUTF-16 LESystem ConfigMicrosoft
بواسطة FileDex
غير قابل للتحويل

Windows Registry format. Platform-specific, conversion not applicable.

أسئلة شائعة

Are REG files dangerous?

Yes. REG files directly modify the Windows Registry when executed. A malicious REG file can disable security features, install autorun malware, or break system functionality. Never run REG files from untrusted sources.

How do I edit a REG file without running it?

Right-click the REG file and choose 'Edit' (opens in Notepad) instead of double-clicking. Alternatively, open any text editor first and drag the file in.

What is the difference between REGEDIT4 and Version 5.00?

REGEDIT4 is the legacy format using ANSI encoding. 'Windows Registry Editor Version 5.00' is the modern format supporting Unicode (UTF-16 LE) and is used by all Windows versions since XP.

ما يميز .REG

What is a REG file?

REG files are text-based scripts that contain Windows Registry entries. When executed, they merge their contents into the Windows Registry, adding or modifying keys and values. REG files are commonly used for system configuration, software deployment, and backing up registry settings.

اكتشف التفاصيل التقنية

How to open REG files

  • Registry Editor (Windows) — Double-click to merge
  • Notepad (Windows) — View/edit as text
  • regedit (Windows) — Import via File menu
  • Any text editor — REG files are plain text

Technical specifications

Property Value
Header Windows Registry Editor Version 5.00
Encoding UTF-16 LE with BOM (or ANSI)
Value Types REG_SZ, REG_DWORD, REG_BINARY, REG_MULTI_SZ
Root Keys HKEY_LOCAL_MACHINE, HKEY_CURRENT_USER, etc.
Delete Syntax Leading minus (-) on key or value

Common use cases

  • System configuration: Tweaking Windows settings.
  • Software deployment: Pre-configuring application settings.
  • Registry backup: Exporting keys for safe-keeping.
  • Group Policy: Alternative to GPO for registry changes.

المرجع التقني

نوع MIME
text/plain
المطوّر
Microsoft
سنة التقديم
1992
معيار مفتوح
لا

البنية الثنائية

REG files are plain-text scripts beginning with a version header line ('Windows Registry Editor Version 5.00' for modern files or 'REGEDIT4' for legacy). Lines contain registry key paths in square brackets followed by value entries as name=type:data pairs. A leading minus sign before a key or value name indicates deletion.

1992Windows 3.1 introduces the Windows Registry and REGEDIT4 format2001Windows XP introduces Registry Editor Version 5.00 format with Unicode support2006Windows Vista adds registry virtualization and UAC prompts for REG imports2012Windows 8 adds PowerShell cmdlets as alternatives to REG file imports
Export a registry key to a REG file أخرى
reg export "HKCU\Software\MyApp" backup.reg /y

Uses the built-in reg.exe tool to export a registry key and all subkeys to a .reg file for backup

Import a REG file into the registry أخرى
reg import settings.reg

Merges the contents of settings.reg into the Windows Registry (requires admin privileges for HKLM keys)

View REG file contents أخرى
type file.reg

Displays the plain-text contents of a REG file in the console without executing it

REG TXT export lossless REG files are already plain text; renaming to .txt prevents accidental execution
REG XML export lossless Export registry entries to XML for structured processing or cross-platform use
عالي

نقاط الضعف

  • Registry modification can disable Windows Defender or firewall
  • Autorun entries can execute malware on startup
  • File association hijacking redirects file opens to malicious programs
  • Social engineering tricks users into merging malicious REG files

الحماية: FileDex does not open, execute, or parse these files. Reference page only.

Built-in Windows GUI for browsing, editing, and exporting registry entries
reg.exe أداة
Command-line tool for querying, adding, exporting, and importing registry data
PowerShell provider exposing HKLM: and HKCU: drives for registry manipulation