Unable to simultaneously satisfy constraints - No constraints in place
Master System Design with Codemia
Enhance your system design skills with over 120 practice problems, detailed solutions, and hands-on exercises.
Introduction
In iOS development, the console warning Unable to simultaneously satisfy constraints can appear even when you think you did not add any constraints yourself. That is not a paradox. It usually means Auto Layout is using constraints you did not notice, such as autoresizing-mask constraints, intrinsic-size constraints, or constraints created by container views.
Where the "Invisible" Constraints Come From
Auto Layout does not require every constraint to come from your code or storyboard lines. UIKit can introduce constraints from several places:
- '
translatesAutoresizingMaskIntoConstraints' - intrinsic content size for labels, buttons, and text fields
- stack views and table view cells
- safe area or container constraints created by Interface Builder
- temporary constraints created during layout passes
So when the console says constraints conflict, it does not mean you explicitly wrote all of them. It means the layout engine ended up with a set of rules that cannot all be true at once.
A Common Programmatic Cause
One of the most common mistakes is adding explicit constraints but forgetting to disable autoresizing-mask translation.
If you leave translatesAutoresizingMaskIntoConstraints as true, UIKit may synthesize constraints from the old autoresizing system. Those implicit constraints then collide with the ones you added manually.
Read the Console Output Carefully
The warning message usually lists the conflicting constraints. Developers often ignore that block because it looks noisy, but it is the main clue.
When reading it, look for:
- one constraint you recognize from your code or storyboard
- one system-generated constraint with
NSAutoresizingMaskLayoutConstraint - a width or height that is impossible given the current container size
- repeated conflicts involving the same view hierarchy
If you see NSAutoresizingMaskLayoutConstraint, that is a strong sign that autoresizing masks are still being converted into constraints somewhere.
Use a Symbolic Breakpoint
A very effective debugging technique is to add a symbolic breakpoint for UIViewAlertForUnsatisfiableConstraints. When the warning occurs, Xcode stops at the moment the conflict is detected, which gives you a much better chance of finding the real source.
This is usually faster than scanning logs after the fact because you can inspect the view hierarchy while the bad layout is active.
Think About Content Compression and Hugging
Not every conflict is about missing anchors. Sometimes the layout is over-constrained because two views both insist on sizes that do not fit.
Examples include:
- a label with long text inside a narrow stack view
- a fixed-width button placed beside a fixed-width image
- a table or collection cell with content that cannot shrink enough
In those cases, the fix may involve content compression resistance, content hugging priority, multiline labels, or relaxing one of the fixed dimensions.
Container Views Create Their Own Rules
Stack views, table view cells, and collection view cells often make the problem look mysterious because they generate or activate constraints on your behalf. If you only inspect the subview you added, you may miss the container rule that actually caused the conflict.
That is why layout debugging is usually about the whole subtree, not one isolated view.
Common Pitfalls
The most common mistake is assuming "I did not add constraints" means there are no constraints. UIKit and Interface Builder add plenty of them.
Another mistake is setting explicit constraints in code while leaving translatesAutoresizingMaskIntoConstraints enabled.
A third pitfall is focusing only on anchor constraints and ignoring intrinsic size, hugging, and compression behavior.
Summary
- The warning can happen even when you did not explicitly create constraints yourself.
- Hidden constraints often come from autoresizing masks, intrinsic content size, or container views.
- Check the console output for
NSAutoresizingMaskLayoutConstraintand other generated rules. - Add a symbolic breakpoint on
UIViewAlertForUnsatisfiableConstraintsto catch the conflict at the source. - Many fixes come from relaxing size assumptions, not just adding more anchors.

