Runtime exceptions
Non-convex MeshCollider with non-kinematic Rigidbody is no longer supported since Unity 5.
The exact message
Non-convex MeshCollider with non-kinematic Rigidbody is no longer supported since Unity 5.Variants of this message
- Non-convex MeshCollider with non-kinematic Rigidbody is no longer supported
- If you want to use a non-convex mesh either make the Rigidbody kinematic or remove the Rigidbody component.
What it means
You have put a MeshCollider with Convex unticked on an object that also has a Rigidbody which is not kinematic. PhysX, the physics engine Unity uses, cannot simulate a concave shape as a moving dynamic body, so the combination is rejected rather than approximated. This is a hard engine constraint rather than a setting you can turn off, so the fix is always to change the collider setup or the body type.
Causes and fixes
Ranked by how often they actually occur, most common first.
A detailed mesh was used directly as a dynamic collider
Dropping a MeshCollider onto an imported model and adding a Rigidbody is the obvious way to make something physical, and it works right up until the object needs to move under physics. PhysX resolves collisions for dynamic bodies using algorithms that require convex shapes, so a concave mesh has no defined inside and cannot be simulated.
The fix: Tick Convex on the MeshCollider. Unity then generates a convex hull of up to 255 faces around the mesh, which is what the physics engine actually simulates. Accept that concavities are filled in: a bowl becomes a solid lump.
The shape genuinely needs to be concave
A convex hull is wrong for anything hollow or recessed: a cup that should hold objects, a room interior, a ring, a vehicle chassis with a cavity. Ticking Convex silently gives you a shape that behaves nothing like the model, which is worse than the error because it fails quietly.
The fix: Build a compound collider instead. Add several primitive colliders, or several convex MeshColliders, to child objects of the Rigidbody. PhysX treats each as a separate convex shape moving together, and the union of convex parts can approximate a concave whole correctly.
The Rigidbody sits on the root; each child contributes one convex piece.
Cup (Rigidbody, no collider) ├── Wall_North (BoxCollider) ├── Wall_South (BoxCollider) ├── Wall_East (BoxCollider) ├── Wall_West (BoxCollider) └── Base (BoxCollider) Colliders on children are owned by the Rigidbody on the parent. Each piece is convex, so PhysX simulates them all; together they describe the concave interior the single mesh could not.Source: Unity Manual: Compound colliders
The object does not need to be dynamic at all
Level geometry frequently has a Rigidbody it does not need, often added to make something collide and then left in place. A concave MeshCollider on a static object is completely valid and is the normal way to collide against terrain, buildings and level meshes. Only the presence of a non-kinematic Rigidbody makes it a problem.
The fix: Remove the Rigidbody. A MeshCollider with no Rigidbody is a static collider, and PhysX handles concave static geometry without difficulty.
The object is moved by script rather than by physics
A platform, a door or a lift driven by animation or by setting transform.position does not need physics to move it, but it does need to push other bodies correctly. A non-kinematic Rigidbody is the wrong tool for that, and it is what triggers this error.
The fix: Tick Is Kinematic on the Rigidbody. A kinematic body is moved by you rather than by forces, it is allowed a concave MeshCollider, and it still pushes dynamic bodies it meets. Move it with Rigidbody.MovePosition inside FixedUpdate so collisions are resolved properly.
MovePosition on a kinematic body sweeps correctly against dynamic bodies.
using UnityEngine; [RequireComponent(typeof(Rigidbody))] public class MovingPlatform : MonoBehaviour { [SerializeField] private Vector3 travel = new(0f, 3f, 0f); [SerializeField] private float speed = 1f; private Rigidbody body; private Vector3 origin; void Awake() { body = GetComponent<Rigidbody>(); body.isKinematic = true; // allows a concave MeshCollider origin = transform.position; } void FixedUpdate() { float t = Mathf.PingPong(Time.time * speed, 1f); body.MovePosition(origin + travel * t); } }Source: Unity Scripting API: Rigidbody.MovePosition, Unity Manual: Rigidbody component, Is Kinematic
How to prevent it
Decide early whether an object is static geometry, a kinematic mover, or a dynamic body, and give it the collider setup that follows from that. Most occurrences of this error are an object that has drifted into the wrong category rather than a genuine physics problem.
Prefer primitive colliders to MeshColliders wherever the shape allows it. A box or a capsule is faster to simulate and never runs into this restriction; a convex MeshCollider is the fallback, not the default.
Author a separate low-detail collision mesh rather than colliding against the render mesh. A convex hull generated from a high-poly model is capped at 255 faces anyway, so the extra detail costs memory and buys nothing.
Treat a silent physics change as suspicious when you tick Convex to clear this error. The object will stop reporting the problem and start behaving like a solid block, which is the outcome you want only if the shape had no meaningful concavity.
Unity version differences
The restriction arrived in Unity 5 with the move to PhysX 3, which is what the message refers to. Earlier versions allowed the combination and simulated it unreliably. It remains in place through Unity 6 and is not configurable.
Related errors
- NullReferenceExceptionWhy Unity throws NullReferenceException, how to read the stack trace to find the exact line, and the five causes that account for nearly all of them.
- Look rotation viewing vector is zeroWhy Quaternion.LookRotation warns that the viewing vector is zero, the four ways a direction ends up zero length, and how to guard against it cleanly.