What is Constraint in MS Project?

Constraint is simply a lock on activity's start or finish date.

When there is no constraint, any delay on the activity will affect the successor activity - it will also be moved forward. But if you have put a constraint on it, it will not move no matter how much its predecessor activity has delayed (moved backward or backwards)

How Constraints Work?

MS Project Constraints

If you apply a start constraint on a task, its start date will not change. There are multiple types of start constraints in MS Project:

1. Must Start On: The start date can neither go backwards no can it go forward.

2. Start No Later Than:  Activity can start earlier than the planned date but not later.

3. Start No Earlier Than: Activity can start later than the planned date but not earlier.

Since, the constraint no 2 and 3 allows some change in start date, these are called flexible start date constraints.

The finish constrains work similar. The following finish constraints are available in MS Project:

1. Must Finish On: The activity finish date can neither move backward nor forward. An interesting thing is that if you will increase duration of the activity that has Must Finish On constraint, it will increase in duration from the beginning, but its finish date will remain intact.

2. Finish No Later Than: The activity can finish earlier than the planned date but not later.

3. Finish No Earlier Than: The activity can finish later than the planned date but not earlier.

Why Use Constraints?

A constraint is used when a task is limited due to resources or technical reasons. Maybe staff is available for limited time or they cannot start before a certain date. Or perhaps material or machinery that will become available then only activity can start. These are some of the reasons that force activities to start or finish at a specific date and not change from that, in any circumstance. 

Constrains are very rarely used and preferably these should be avoided since completing a task while also considering its constraint is often too difficult or impossible.

Also read:

What is Status Date in MS Project and how to Use it?

Differences between MS Project and Primavera