Unity Update vs FixedUpdate is one of the most common topics that every Unity developer should understand. Choosing the wrong method can lead to inconsistent player movement, physics issues, and unexpected gameplay behaviour.
When developing games in Unity, I use Update() and FixedUpdate() for different purposes. Although both methods run repeatedly during gameplay, they don't work in the same way.
For example, should you read player input inside Update or FixedUpdate? Where should you move a Rigidbody? And when should you use LateUpdate?
In this article, I'll explain the differences between these methods using simple examples. I'll also share some common mistakes I avoid in my Unity projects and explain when I use each method.
Let's get started!
1. What Is Update() in Unity?
Update() is a Unity event function that runs once per rendered frame.
Its execution depends on the game's frame rate (FPS).
For example:
- At 30 FPS, Update runs approximately 30 times per second.
- At 60 FPS, Update runs approximately 60 times per second.
- At 120 FPS, Update runs approximately 120 times per second.
This means Update does not have a fixed execution time.
When Should You Use Update()?
I generally use Update for:
- Reading keyboard, mouse, and player input.
- Updating UI elements.
- Handling gameplay logic.
- Checking player actions.
- Updating timers and cooldowns.
- Moving objects without Rigidbody physics.
Example: Player Movement Using Update()
If your player doesn't use Rigidbody physics, you can move it directly using Update.
using UnityEngine;
public class PlayerMovement : MonoBehaviour
{
[SerializeField] private float speed = 5f;
void Update()
{
float horizontal = Input.GetAxis("Horizontal");
float vertical = Input.GetAxis("Vertical");
Vector3 movement = new Vector3(
horizontal, 0, vertical
);
transform.Translate(
movement * speed * Time.deltaTime,
Space.World
);
}
}
Why do I use Time.deltaTime?
Because Update runs at different frame rates. Without Time.deltaTime, the player may move faster on devices with higher FPS and slower on devices with lower FPS.
Using Time.deltaTime helps keep movement speed consistent.
My approach: I use Update for regular gameplay logic, input reading, and non-physics-based movement.
2. What Is FixedUpdate() in Unity?
FixedUpdate() is another Unity event function, but unlike Update, it runs at a fixed time interval.
By default, Unity calls FixedUpdate every 0.02 seconds, which means 50 times per second.
You can change this value from:
Edit → Project Settings → Time → Fixed Timestep
FixedUpdate is mainly designed for physics-related operations.
When Should You Use FixedUpdate()?
I use FixedUpdate for:
- Moving Rigidbody objects.
- Applying forces.
- Applying torque.
- Physics-based jumping.
- Changing Rigidbody velocity.
- Performing physics-related calculations.
Example: Rigidbody Movement Using FixedUpdate()
If your player uses a Rigidbody component, it's better to handle physics movement inside FixedUpdate.
using UnityEngine;
public class PlayerPhysicsMovement : MonoBehaviour
{
[SerializeField] private Rigidbody rb;
[SerializeField] private float speed = 5f;
private Vector3 movement;
void Update()
{
float horizontal = Input.GetAxis("Horizontal");
float vertical = Input.GetAxis("Vertical");
movement = new Vector3(
horizontal, 0, vertical
);
}
void FixedUpdate()
{
Vector3 newPosition =
rb.position + movement * speed * Time.fixedDeltaTime;
rb.MovePosition(newPosition);
}
}
Here, I read player input inside Update and move the Rigidbody inside FixedUpdate.
This is a useful approach because input handling and physics calculations have different update requirements.
My approach: Whenever I'm working with Rigidbody physics, I prefer FixedUpdate for physics operations.
3. Unity Update vs FixedUpdate: Main Differences
Let's understand the main differences between Update and FixedUpdate.
Important: FixedUpdate doesn't always run once per frame. Depending on the frame rate, Unity may call it multiple times or skip it during a particular rendered frame.
4. What Is LateUpdate() in Unity?
Apart from Update and FixedUpdate, Unity also provides LateUpdate().
LateUpdate runs after all Update methods have finished for the frame.
I mainly use it when one object needs to follow another object after its movement is complete.
Example: Camera Follow Using LateUpdate()
Imagine a player moving forward and a camera following that player.
If both the player and camera update their positions independently inside Update, their execution order can sometimes cause camera jitter.
For a simple transform-based player movement system, LateUpdate is a good choice.
using UnityEngine;
public class CameraFollow : MonoBehaviour
{
[SerializeField] private Transform target;
[SerializeField] private Vector3 offset;
void LateUpdate()
{
if (target == null)
return;
transform.position = target.position + offset;
}
}
The player updates its position first, and then the camera follows.
My approach: I use LateUpdate for camera follow systems and other operations that depend on objects updated during Update.
5. Common Mistakes I Avoid in Unity
Understanding these methods is important, but knowing what to avoid is equally important.
Here are some common mistakes I try to avoid in my Unity projects.
1. Moving Rigidbody Objects Using Transform
Avoid directly changing the Transform position when you want an object to behave according to Rigidbody physics.
void Update()
{
transform.position += Vector3.forward * speed * Time.deltaTime;
}
Instead, use Rigidbody methods such as MovePosition() inside FixedUpdate for kinematic movement.
2. Forgetting Time.deltaTime
Without Time.deltaTime, movement speed depends on the frame rate.
// Avoid
transform.Translate(Vector3.forward * speed);
Use:
// Better
transform.Translate(
Vector3.forward * speed * Time.deltaTime
);
3. Reading Input Only Inside FixedUpdate
I generally avoid reading player input only inside FixedUpdate.
Input events can happen between physics updates, so some input events may be missed depending on the input system and configuration.
Instead, capture input using Update or the appropriate Input System callbacks and pass it to your physics logic.
4. Calling Expensive Methods Every Frame
Avoid repeatedly searching for objects inside Update when you can cache their references.
// Avoid
void Update()
{
FindObjectOfType<GameManager>();
}
Better approach:
private GameManager gameManager;
void Awake()
{
gameManager = FindFirstObjectByType<GameManager>();
}
void Update()
{
if (gameManager == null)
return;
// Use cached reference
}
This avoids performing the same object search every frame.
5. Using FixedUpdate for Everything
FixedUpdate is not a performance optimization method for all gameplay logic.
It is designed for physics-related operations. Moving UI updates, regular gameplay checks, and unrelated calculations into FixedUpdate doesn't automatically make your game faster.
Always choose the method based on what the code needs to do.
6. My Practical Approach: Which Method Do I Use?
Here is a simple reference that you can follow while developing your Unity games.
Remember that these are general guidelines. Some situations require a different approach depending on your game's architecture and requirements.
Conclusion: Unity Update vs FixedUpdate
Choosing between Update, FixedUpdate, and LateUpdate becomes easier once you understand their purpose.
Here is a quick summary of what I recommend remembering:
- Update(): Use it for player input, UI updates, and regular gameplay logic.
- FixedUpdate(): Use it for Rigidbody movement, applying forces, and physics calculations.
- LateUpdate(): Use it for camera follow and operations that should happen after Update.
- Time.deltaTime: Use it for frame-rate-independent movement and time-based calculations in Update.
- Time.fixedDeltaTime: Use it for time-based calculations inside FixedUpdate.
- Cache references: Avoid repeatedly searching for objects inside Update.
- Don't mix physics and Transform movement: Choose the correct movement approach for your Rigidbody setup.
A simple rule I follow is: Use Update for gameplay, FixedUpdate for physics, and LateUpdate when execution order matters.
Understanding these small differences can help you write cleaner scripts, avoid common physics problems, and build more reliable Unity games.
Thanks for reading! ❤️
I hope this article helped you understand the difference between Unity Update and FixedUpdate.
If you found it useful:
- 👍 Give this article a like.
- 🔁 Share it with other Unity developers.
- 💬 Leave a comment and share how you use Update and FixedUpdate in your projects.
- ⭐ Follow me for more Unity development tips, tutorials, and practical programming guides.
Happy Game Development! 🎮


Top comments (0)