What is a "god class" and which SOLID principle does it violate?

Answer

A God Class (also called a Blob anti-pattern) is a class that knows too much or does too much — it accumulates an excessive number of responsibilities over time, becoming the central hub of an application. Symptoms include hundreds or thousands of lines of code, dozens of methods spanning unrelated concerns (authentication, business logic, data access, formatting), and every other class depending on it. A God Class primarily violates SRP — it has many reasons to change. It also tends to violate OCP (modification is needed for any new feature), DIP (it's often tightly coupled to many concrete classes), and ISP (it often forces clients to depend on a large, bloated interface). Refactoring a God Class involves identifying distinct responsibilities and extracting them into focused classes.