# Area in Godot 4: it is Area3D now

Area is called Area3D in Godot 4, matching Area2D. In a Godot 4 project, extends Area fails to parse with Could not find base class "Area".

Source: https://flockbay.com/godot/area-in-godot-4/ · Updated 2026-10-30

## What Godot is checking

GDScript resolves the class after extends when the script loads. Area is not a class in Godot 4, so the script fails to parse and nothing in it runs.

The converter carries Area to Area3D. Its body_entered, body_exited, area_entered and area_exited signals keep their names; connect them through the signal now, body_entered.connect(...).

## Reproduce it

A Godot 3 script that extends Area, in a Godot 4 project. The scene is one Node carrying it.

```
extends Area

func _ready():
	print("ready")

```

## What Godot 4.7.2 prints

```
Godot Engine v4.7.2.stable.mono.official.ed1daf0bf - https://godotengine.org

SCRIPT ERROR: Parse Error: Could not find base class "Area".
   at: GDScript::reload (res://answers/area-in-godot-4/repro.gd:1)
ERROR: Failed to load script "res://answers/area-in-godot-4/repro.gd" with error "Parse error".
   at: load (modules/gdscript/gdscript_resource_format.cpp:46)
```

## Fix it

A trigger that extends Area3D and connects its body_entered signal.

```
extends Area3D

func _ready() -> void:
	body_entered.connect(_on_body_entered)
	print(get_class(), " monitoring: ", monitoring)

func _on_body_entered(body: Node3D) -> void:
	print("entered: ", body.name)

```

## What the fixed script prints

```
Godot Engine v4.7.2.stable.mono.official.ed1daf0bf - https://godotengine.org

Area3D monitoring: true
```

## Run this fix with your agent

Flockbay is the Godot editor with an AI agent built in. Paste this into Flockbay's chat, or into Claude Code or Codex connected to Flockbay over MCP: the agent finds the cause in your project, applies the fix, runs the game headless and reads Godot's output to check it.

```
My Godot project was written for Godot 3 and Godot 4 stops on this: "Parse Error: Could not find base class "Area".". Port every use to Godot 4. Area is called Area3D in Godot 4, matching Area2D. In a Godot 4 project, extends Area fails to parse with Could not find base class "Area". Then run the game headless and check Godot's output for errors.
```

## Verified on Godot 4.7.2

Both scripts on this page were run headless on Godot 4.7.2 (4.7.2.stable.mono.official.ed1daf0bf) on 18 October 2026, and the output above is what Godot printed, unedited.

Where the check lives in Godot's source: [renames_map_3_to_4.cpp line 1464, Area to Area3D](https://github.com/godotengine/godot/blob/4.7.2-stable/editor/project_upgrade/renames_map_3_to_4.cpp#L1464), [Area3D class reference](https://github.com/godotengine/godot/blob/4.7.2-stable/doc/classes/Area3D.xml).

## Questions

### Why does body_entered never fire?

The body needs a collision shape, and its collision_layer must be in the area's collision_mask.

### Can I disable the shape inside the callback?

Only deferred: set_deferred("disabled", true), or Godot refuses while it flushes physics queries.

Download Flockbay free: Flockbay's agent reads Godot's debugger output and fixes errors like this one in your project, on the official Godot. https://flockbay.com/download/

Related: [StaticBody in Godot 4: it is StaticBody3D now](/godot/staticbody-in-godot-4/), [RigidBody in Godot 4: it is RigidBody3D now](/godot/rigidbody-in-godot-4/), [CollisionShape in Godot 4: it is CollisionShape3D now](/godot/collisionshape-in-godot-4/), [Can't change this state while flushing queries. Use call_deferred() or set_deferred() to change monitoring state instead in Godot 4](/godot/cant-change-this-state-while-flushing-queries/), [Every verified Godot 4 answer](/godot/), [Does Flockbay change my Godot project?](/docs/does-flockbay-change-my-godot-project/)
