How Dangerous is Editing the Windows Registry?

  • Thread starter WWGD
  • Start date
  • #1
WWGD
Science Advisor
Gold Member
7,079
10,707
TL;DR Summary
I've seen, heard of people editing the registry . Some , though, warn of the dangers of incorrect editing. Who should we believe?
Hi, curious as to do something I want to do on My Win10 PC, which requires editing the registry.

Some refer to doing it casually, while others warn of the perils of doing it incorrectly, which may freeze or crash the system. I believe we can do a backup of the registry database before making the changes, which can be used in case the edits don't work out or cause some damage.
What's your take, experience here?
 
  • Like
Likes DeBangis21
Computer science news on Phys.org
  • #2
If you corrupt the Registry, Windows won't run. Dire enough for you?
 
  • Like
Likes DeBangis21 and WWGD
  • #3
Vanadium 50 said:
If you corrupt the Registry, Windows won't run. Dire enough for you?
Thank you. Is it possible to back up the registry and use it to undo any resulting corruption? Maybe @Wrichik Basu or @newjerseyrunner , @Tom.G would know?
 
Last edited:
  • #4
Sure, you can back it up. The better question, though, is whether you can restore it. If the corruption is a little bad, no problem. If it's very bad, and Windows won't start, how do you plan to restore it?
 
  • Like
Likes symbolipoint, DeBangis21 and WWGD
  • #5
Vanadium 50 said:
Sure, you can back it up. The better question, though, is whether you can restore it. If the corruption is a little bad, no problem. If it's very bad, and Windows won't start, how do you plan to restore it?
Ok, but, then, this editing is never done, then?
 
  • #6
Of course it is. But there is risk. You have the ability to make things much worse.
 
  • #7
It's like anything else. Using a flamethrower for a controlled burn is done - by trained professionals, but you would be unwise ro attempt it yourself if you were not experienced with flamethrowers and burn techniques.

Registry editing can be done. I have done it, and I'm no tech-head. Just don't make any mistakes.
 
  • Like
Likes WWGD
  • #8
I have done it, but VERY carefully and with some sweat and a few cusswords involved, not because it's hard to do but because it's so potentially dangerous. You need to be really sure in advance that you know what you need to do and you need to be very careful doing it.

Some registry changes are trivial, like going in and locating a particular value and changing it from a 0 to a 1. Other changes can be complex.
 
  • Like
Likes Vanadium 50, russ_watters, Borg and 1 other person
  • #9
Yes it is possible.

That said, for other than very minor edits, you better have another disk drive available, same make, size, and model as your system drive, and an external drive copier that does not need a computer to clone a drive. That is CLONE, a drive, not backup or copy it. You need something that will boot. That way you can swap the cloned drive into the computer, boot up, and start over. I recommend you pull out the Boot Drive and clone it before diving into the registry for other than looking around.

The real problem arises because the Registry structural details are not readily available, if at all. It is a tree-structured data base scattered across several (4 or 5?) files. I have 6 different books on the Registry and still can't track down many of the cross-links. Some links are in Binary and some in Plain Text.

One current problem I've run into is: How to have a particular filetype associate with a particular program. There seems to be a chain of references/links at least 3 elements long that are involved. For instance to get your Editor to open a .LTR filetype, you may have to uninstall then reinstall the Editor, and all the Editor presets you have customized. This was broken by a disk crash 4 or 5 months ago.

For complex changes that are not likely to crash the system or make it unbootable, I save the pertinent registry entries to a text file ('export' command), make a copy of the file, and edit the copy. Then print both files and the next day read and compare the two print-outs. If/when all looks good, the edited file is imported to the registry and tested. If no joy, I can import the saved original and start over.

An useful example file to add a command to a right-click on a directory is at:
https://www.sevenforums.com/tutorials/47415-open-command-window-here-administrator.html

Have Fun Learning!
Tom

p.s. don't try to print the whole registry, many lines are longer than the paper and you can easily go thru a case of paper! also, the binary links are not printed.
 
  • Like
Likes WWGD
  • #10
If you do know what you are doing (and has a backup) then it's fine: there are problems when there is no way around it (it's the easy way around many other problems, actually).

If you don't, then it's just like Chernobyl.
 
  • Like
  • Haha
Likes Tom.G and WWGD
  • #11
You didn't say for what purpose you might need to edit the registry (there might be another way).

Regarding backing up the registry before editing: rather than trying to manually backup the registry hive files, the simplest and safest way to way to do an effective backup, so that you have the option post-edit to regress the changes you made, is to use System Restore: from the run box or command prompt, enter sysdm.cpl

You get a Systems Properties dialog box like this:

1715671186303.png


Press the Create button to create a Restore Point for the 'pre-edit system', which can later be used to 'back out' the changes: from the run box or command prompt, enter rstrui.exe
 
  • Like
Likes WWGD, russ_watters and Borg
  • #12
Yeah, as a general question it's tough to answer. I've edited the registry dozens of times but always very specific and minor edits, like removing programs from the startup list or deleting entries from a program that didn't fully uninstall. I've never had an issue.
 
  • Like
Likes WWGD
  • #13
sysprog1 said:
System Restore: from the run box or command prompt, enter sysdm.cpl
Don't you need to start Windows to use System Restore to recover a Restore Point?

If not, please enlighten us by describing the procedure.

Cheers,
Tom
 
  • Like
Likes Vanadium 50 and WWGD
  • #14
When you first load Windows, you should create a backup/recovery disk. You can then use it to reboot and as long as you did not foolishly leave the Restore Point file on a disk that that process will wipe out, then you just use it to recover.

If you didn't create a backup/recovery disk, well ... tough!
 
  • Like
Likes WWGD
  • #15
If you visit Google, you will find many people who tried to restore the registry, without success. Happened to me once as well. Backup is only half of the story.

I don't think it was an improvement over its predecessor, INI files. But we're stuck with it now. But it's fragile.
 
  • Like
Likes PeroK
  • #16
Is uranium dangerous?

No, not for most people. But if you know what you're doing it can be very dangerous.

Editing the registry is the opposite.
 
  • Haha
  • Like
Likes pinball1970, Vanadium 50 and Tom.G
  • #17
gmax137 said:
Is uranium dangerous?

No, not for most people. But if you know what you're doing it can be very dangerous.
Instructions unclear, so I sprinkled my uranium on toast.
 
  • Like
  • Haha
Likes pinball1970 and gmax137
  • #18
Tom.G said:
Don't you need to start Windows to use System Restore to recover a Restore Point?

If not, please enlighten us by describing the procedure.

Cheers,
Tom
If a registry-edit-engendered error is preventing Windows from starting normally, then booting into 'Safe Mode' should be tried. On most PCs, hitting F8 repeatedly about once per second during bootup will get you to a startup menu that includes Safe Mode as an option, but the exact procedure can vary. Safe Mode doesn't load the entire system, and usually can start even if a registry error is preventing normal startup. If you can't get into normal Safe Mode, you can try Safe Mode with Command Prompt, at which point you can exercise command-based options such as copying and renaming registry hive files.
 
  • Like
Likes phinds
  • #19
russ_watters said:
I sprinkled my uranium on toast.
Was it toast before you sprinkled it? Or just bread.
 
  • #20
A question that should be asked is "Why?"

Think of it like a strong drug. Maybe you need it. Maybe it will make you sick or worse. You should only do this if you have a very good reason and idea of what you are trying to accomplish. Sometimes you really want to leave bad enough alone.
 
  • #21
Vanadium 50 said:
...idea of what you are trying to accomplish.
Seems to me that is what triggers the thought to action in the first place.

As usual, the implementation is where the rubber hits the road,... or the brown stuff enters the air circulation system.
 
  • Like
Likes gmax137
  • #22
A good idea is probably to run one or more of these programs who “claims” to clean up your registry. But be careful which ones you select. Perhaps that would take care of your problem without you having to manually edit the registry.
 
  • Like
Likes WWGD
  • #23
WWGD said:
TL;DR Summary: I've seen, heard of people editing the registry . Some , though, warn of the dangers of incorrect editing. Who should we believe?

Hi, curious as to do something I want to do on My Win10 PC, which requires editing the registry.

Some refer to doing it casually, while others warn of the perils of doing it incorrectly, which may freeze or crash the system. I believe we can do a backup of the registry database before making the changes, which can be used in case the edits don't work out or cause some damage.
What's your take, experience here?
The Win reg is a reference point for everything. I once wrote a project in Excel VBA (with API), and used cell references to give read/write values to my application in THAT environment. Was easier than selecting a reg key to go to...Bottom Line: If you know the application and 'all over the place' in the reg where it references... do it. IF NOT... feel shot in the head....lol
 
  • #24
WWGD said:
TL;DR Summary: I've seen, heard of people editing the registry . Some , though, warn of the dangers of incorrect editing. Who should we believe?

Hi, curious as to do something I want to do on My Win10 PC, which requires editing the registry.

Some refer to doing it casually, while others warn of the perils of doing it incorrectly, which may freeze or crash the system. I believe we can do a backup of the registry database before making the changes, which can be used in case the edits don't work out or cause some damage.
What's your take, experience here?
 
  • #25
Also Win reg is dynamic, meaning EVERYTHING you or an app does changes reg values....Kinda a time machine...
 
  • Like
Likes WWGD
  • #26
Gifovaco said:
Also Win reg is dynamic, meaning EVERYTHING you or an app does changes reg values....Kinda a time machine...
No, not nearly everything, but most important things.
 
  • #27
sbrothy said:
A good idea is probably to run one or more of these programs who “claims” to clean up your registry. But be careful which ones you select. Perhaps that would take care of your problem without you having to manually edit the registry.
I've used Revo Uninstaller (there's a free portable version available) with good results -- I note that it always creates a restore point before it does 'anything else that could matter'.
 
  • Like
Likes WWGD
  • #28
sysprog1 said:
I've used Revo Uninstaller (there's a free portable version available) with good results -- I note that it always creates a restore point before it does 'anything else that could matter'.
But is the restore point helpful if the change in the registry freezes your PC?
 
  • #29
WWGD said:
But is the restore point helpful if the change in the registry freezes your PC?
Yes. Each 'restore point' associates with a specific backup copy of the registry hive files. If your pc is not startable from the device containing the befouled registry -- not even in 'Safe mode with Command Prompt', then you can boot from a different device, e.g. a flash drive, and then do renames on the hive files to effectively restore from the backup versions.
 
  • Like
Likes WWGD
  • #30
Now I’m “running” Linux and it’s been a while since I’ve have to deal with the Windoze, but I seem to remember that you can save the entire registry to a .reg file. How much good that will do you if you mess up some important boot-settings I’m not sure, but at least you might be able to get in via some kind of safe mode and restore the thing. Happy hacking! :)

EDIT: Yeah, so basically what @sysprog1 said.

EDIT2: I dunno what happened to the names there. Sorry.
 
  • Like
Likes WWGD
  • #31
phinds said:
No, not nearly everything, but most important things.
I get that, my incorrect exactness... But it do change what 'She' cares about....haha
 
  • #32
Some details of the registry format can be found here:

http://www.sentinelchicken.com/data/TheWindowsNTRegistryFileFormat.pdf

KB822705 on the Microsoft website

https://www.google.com/search?hl=en&q=Registry+Overview+Windows+NT+site:microsoft.com

https://www.google.com/search?&hl=en&q=The+Windows+NT+Registry+File+Format.pdf

https://www.yumpu.com/en/document/view/19143045/windows-nt-registry-file-regf-format-specification



Books:
Windows XP Registry, ISBN0-7821-2987-0 (SYBEX)
Windows XP Registry Guide, ISBN 0-7356-1788-0 (Microsoft Press)
The Windows 95 Registry, ISBN 1-55828-494-X (MIS Press)
Inside The Windows 95 Registery, ISBN 1-55692-170-4 (O'Reilly & Associates)

Cheers,
Tom
 
  • Like
Likes WWGD
  • #33
sbrothy said:
A good idea is probably to run one or more of these programs who “claims” to clean up your registry. But be careful which ones you select. Perhaps that would take care of your problem without you having to manually edit the registry.
No, this is not good advice. The very fact that you put "claims" in scare quotes should be a red flag.
 
  • #34
WWGD said:
curious as to do something I want to do on My Win10 PC, which requires editing the registry.
I'm having difficulty imagining something requiring that that would be worth the risk.
 
  • #35
PeterDonis said:
No, this is not good advice. The very fact that you put "claims" in scare quotes should be a red flag.
Touche. One can check them out before running them though. Some may be malware but not all of them. But yeah, if you’re at the OP’s tech level choosing correctly might not be so easy. Disregard my faulty advice.
 
  • Like
Likes gmax137

Similar threads

  • Computing and Technology
Replies
7
Views
8K
  • Computing and Technology
Replies
24
Views
8K
  • Computing and Technology
Replies
12
Views
2K
Replies
14
Views
2K
  • Computing and Technology
2
Replies
37
Views
5K
  • Computing and Technology
Replies
6
Views
4K
Replies
6
Views
4K
Replies
2
Views
1K
  • Programming and Computer Science
Replies
3
Views
2K
Replies
6
Views
2K
Back
Top