At my workplace (medium-sized software company), I am the sole developer responsible for a lot of code that consists of a collection of dozens of scripts (totals 400K lines of code) that has hundreds of internal stakeholders. If the code doesn't run, entire departments are basically unable to do their work. Furthermore, due to the nature of the code, it doesn't just run on its own, but needs continuous monitoring, e.g. to handle bugs or new use-cases that arise unexpectedly.

The code is in an old programming language, it is badly written, and it is impossible to know what's going on without months of debugging through it. This is how I learned it, and then the guy who wrote it stopped, and now it's just me.

So I consider myself "irreplaceable" at work. With that in mind, why is it then frowned upon that I use this irreplaceability as leverage to ask for a pay raise? And not just a small one either, I'm thinking at least 50 % --- how are they going to say no? They literally cannot fire me.