Never been fired, but I did get made redundant once.
A previous employer - a software engineering house - went out looking for new business and were very pleased to get what to them was a big (multimillion GBP) contract on a large transportation system.
They were taking the project on from a different company that had given it up/been fired by the primary contractor (which should have set off alarm bells, but evidently didn’t). Anyway, my employer went on a rapid hiring run to get all the software engineers they needed.
It wasn’t my project but I got roped into doing some of the verification work (software verification = blech). One look at the design we’d inherited and it was obvious the whole thing needed to be thrown in the bin. It was an utter clusterfuck. Somebody didn’t do due diligence at our end, we never should have touched it with a bargepole.
Turns out we’d got the contract by massively under-estimating how much work was needed. So after a few months of not being able to deliver the impossible things we’d promised, the customer canned us over a weekend, and suddenly we had twice as many software engineers as we now needed.
I was a fairly recent hire, which meant I got binned as part of the Last In, First Out principle. Sucky job, anyway. I walked around the corner and into a better job with our parent company, which eventually led me to where I am now so it all worked out.