
Unity 3D Audio Bug: Spatial Sound Not Working Correctly
February 14, 2026
Unity Root Motion Bug: Character Sliding or Teleporting
February 14, 2026You expect a collision to happen. Two objects clearly touch. But OnCollisionEnter() never fires. No debug log. No reaction. Nothing.
This issue is often described as a “Unity collision detection bug.” In reality, Unity’s physics system is strict about its rules. If even one condition is not met, collision messages will not be sent.
This article explains why OnCollisionEnter() is not called and how to fix it step by step.
How OnCollisionEnter Works
OnCollisionEnter(Collision collision) is triggered when two non-trigger colliders make physical contact and at least one of them has a Rigidbody.
Basic example:
void OnCollisionEnter(Collision collision)
{
Debug.Log("Collided with: " + collision.gameObject.name);
}
If this method is not firing, one of the required conditions is missing.
Rule 1: At Least One Object Must Have a Rigidbody
This is the most common cause.
Collision messages will only fire if:
- At least one object has a Rigidbody
- Both objects have Colliders
- Is Trigger is NOT enabled
If both objects only have Colliders and no Rigidbody, Unity will not send collision callbacks.
Common Mistake: Using Two Static Colliders
If both objects are static (no Rigidbody), they can physically overlap visually but no collision event will be triggered.
Fix: Add a Rigidbody to at least one object.
Rule 2: Is Trigger Must Be Disabled
If either collider has Is Trigger enabled, Unity will not call OnCollisionEnter(). Instead, it will use trigger events.
In that case, you must use:
void OnTriggerEnter(Collider other)
{
Debug.Log("Trigger entered");
}
Make sure you are using the correct method for your collider type.
Rule 3: Collision Layers Must Interact
Unity allows you to disable collisions between layers.
Check:
- Edit → Project Settings → Physics
- Layer Collision Matrix
If the layers of the two objects are unchecked, collisions will never occur.
Rule 4: Object Must Not Be Kinematic (In Some Cases)
If both Rigidbodies are set to Kinematic and moved manually using transform.position, collision events may not fire correctly.
Better approach for physics movement:
void FixedUpdate()
{
rb.MovePosition(rb.position + Vector3.forward * speed * Time.fixedDeltaTime);
}
Always move physics objects inside FixedUpdate().
Rule 5: Objects Must Actually Collide Physically
Sometimes objects appear to touch visually, but their Colliders do not overlap.
Common reasons:
- Incorrect collider size
- Mesh collider mismatch
- Wrong scaling
- Objects slightly offset
Enable Gizmos in the Scene view to inspect collider shapes.
Rule 6: Fast Moving Objects Passing Through
If objects move very fast, they may pass through each other between physics steps.
Fix this by changing Collision Detection mode:
- Select Rigidbody
- Set Collision Detection to Continuous
This prevents tunneling issues.
Rule 7: Script Attached to Wrong Object
Another simple but common issue: the script containing OnCollisionEnter() is not attached to the object that has the Collider or Rigidbody.
The method must exist on one of the colliding objects.
Rule 8: Wrong Method Signature
The method must match exactly:
void OnCollisionEnter(Collision collision)
If you misspell it or use the wrong parameter type, Unity will not call it.
This will NOT work:
void OnCollisionEnter(Collider other)
How to Debug the Issue
Use this checklist:
- Does at least one object have a Rigidbody?
- Is Is Trigger disabled?
- Are layers allowed to collide?
- Are colliders properly sized?
- Is the script attached to the correct object?
- Is the method signature correct?
- Are objects moving in FixedUpdate?
Going through this list solves most cases.
Special Case: Collision With CharacterController
If you are using a CharacterController component instead of a Rigidbody, collision messages behave differently.
You may need to use:
void OnControllerColliderHit(ControllerColliderHit hit)
CharacterController does not use standard Rigidbody collision callbacks.
Is This a Unity Bug?
In almost all cases, no. Unity’s physics system follows strict rules. If those rules are not met, collision events will not fire.
True engine-level collision bugs are rare.
Best Practices for Reliable Collision Detection
- Always use at least one Rigidbody
- Move physics objects in FixedUpdate
- Use Continuous detection for fast objects
- Double-check layer collision matrix
- Use triggers only when needed
Conclusion
If OnCollisionEnter() is not being called, the issue is almost always configuration-related. Missing Rigidbody, trigger settings, layer restrictions, or incorrect movement methods are the most common causes.
Once you understand Unity’s collision rules, the system becomes predictable and reliable.
Proper setup prevents hours of debugging and ensures stable physics interactions in your game.










