What is the term for a special method that initializes a new object?

The story behind the answer

The term for a special method that initializes a new object is constructor. In Java, a constructor prepares an instance for use by assigning initial field values, checking or transforming arguments, and establishing the object’s starting state.

A Java constructor has the same name as its class and does not declare a return type—not even void. It is invoked as part of a new expression, such as new Account("Ava"), rather than being called like an ordinary method. Constructors can be overloaded, allowing a class to offer several initialization paths with different parameter lists.

If a class declares no constructor, the compiler supplies a default no-argument constructor, provided the superclass can be initialized appropriately. A constructor can also invoke another constructor in the same class with this(), or a superclass constructor with super(); such constructor calls must appear first.

Initializer, finalizer, and destructor are related terms but are not the canonical answer here. In particular, Java has no deterministic destructor mechanism: garbage collection handles unreachable objects, while cleanup resources are normally managed with APIs such as AutoCloseable.

Source: Wikipedia · fact-checked Aug. 2026

Add question to a list

Choose a list to keep this question in: