The Error State Kalman Filter (ESKF) is an estimation algorithm that tracks a small error state—the deviation between a high-fidelity nonlinear nominal state and the true state—while the nominal state is propagated using a full nonlinear model. This separation allows the filter to operate primarily in a local, linear error space where the Kalman filter assumptions hold, while the bulk of the motion is handled by the more accurate nonlinear integration. It is especially advantageous for attitude estimation using quaternions or rotation matrices, as it avoids singularities and constraints inherent in directly filtering orientation states.
Glossary
Error State Kalman Filter (ESKF)

What is Error State Kalman Filter (ESKF)?
The Error State Kalman Filter (ESKF) is a specialized variant of the Kalman filter designed for robust and numerically stable state estimation in nonlinear systems, particularly in robotics and aerospace.
The ESKF's core mechanics involve a two-step process: a prediction step where the nominal state is integrated forward and the error state's covariance is propagated linearly, and an update step where sensor measurements are used to correct the small error state. This corrected error is then injected back into the nominal state, which is reset. This architecture provides superior numerical stability and often better handles the strong nonlinearities of 3D rotation compared to a direct Extended Kalman Filter (EKF). It is a foundational technique in modern visual-inertial odometry (VIO) and inertial navigation systems (INS).
Key Features of the ESKF
The Error State Kalman Filter (ESKF) is a specialized variant of the Kalman filter designed for robust state estimation in nonlinear systems, particularly in robotics and aerospace. Its core innovation is operating on the error state—the small deviation between a nominal state and the true state—rather than the full state itself.
Error-State Formulation
The ESKF's defining characteristic is its separation of state into a nominal state and a small error state. The nominal state is propagated using the full, often nonlinear, system dynamics. The ESKF's core Kalman filter equations operate only on the linearized error state, which is assumed to be small. This separation provides two key benefits:
- Numerical Stability: The error state remains small and well-behaved, avoiding issues like covariance matrix ill-conditioning that can occur when directly estimating large states (e.g., global position).
- Efficiency: The error state's covariance matrix is smaller, as it only tracks uncertainties for the error, not the full state magnitude.
Intrinsic Handling of Manifolds (e.g., SO(3))
This is the ESKF's most celebrated advantage for attitude estimation. Orientation (rotation) does not live in linear Euclidean space but on the special orthogonal group SO(3), a nonlinear manifold. The ESKF elegantly handles this:
- The nominal orientation is represented correctly on the manifold (e.g., as a quaternion or rotation matrix).
- The orientation error state is represented in the tangent space—the local linear space around the nominal orientation—typically as a minimal 3D vector (e.g., axis-angle).
- This structure inherently avoids the singularities and normalization issues of directly filtering quaternions with an Extended Kalman Filter (EKF), providing more consistent and stable orientation estimates.
Reset Operation and Observability
A unique step in the ESKF cycle is the error state reset. After the Kalman update corrects the error state, this correction is injected into the nominal state, and the error state is reset to zero (its mean) with its covariance updated accordingly.
- This reset keeps the error state small, validating the linearity assumptions made during prediction and update.
- It naturally enforces the observability properties of the underlying system. Unobservable directions in the error state (like global yaw in a visual-inertial system without absolute references) see their covariance grow unbounded, while observable directions are constrained, preventing the filter from becoming overconfident in unobservable states.
Robustness to Nonlinearities
By confining linearization to the (small) error state, the ESKF is more robust to system nonlinearities than a standard EKF. The EKF linearizes the full nonlinear model around the current state estimate, which can be a poor approximation if the state is far from the linearization point. In contrast, the ESKF:
- Uses the true nonlinear model to propagate the nominal state, capturing large motions accurately.
- Only linearizes the error dynamics, which are simpler and vary slowly because the error is small. This two-tier approach generally provides better fidelity and convergence, especially for highly nonlinear systems like agile drones or legged robots.
Modularity and Integration with Optimization
The ESKF's structure makes it a natural fit for hybrid filtering-optimization architectures common in modern robotics. The nominal trajectory can be seen as a prior or initial guess. The ESKF's error-state update provides an efficient, recursive way to compute corrections to this trajectory.
- This output can be fed into a factor graph or batch optimization (like a sliding-window smoother) as a precise probabilistic constraint, blending the efficiency of filtering with the accuracy of smoothing.
- It cleanly separates high-frequency prediction (IMU integration in the nominal state) from lower-frequency, complex correction updates (from cameras or LiDAR in the error state).
Comparison to EKF and UKF
The ESKF occupies a distinct niche between the Extended Kalman Filter (EKF) and Unscented Kalman Filter (UKF).
- vs. EKF: The EKF linearizes the full state dynamics. For attitude, this leads to complex Jacobians and potential singularity issues. The ESKF's manifold-aware error state is simpler and more stable.
- vs. UKF: The UKF uses sigma points to propagate statistics through nonlinearities without explicit Jacobians, often outperforming the EKF. However, the UKF still operates on the full state on the manifold, which can be less efficient. The ESKF often matches UKF accuracy for attitude estimation while being more computationally efficient due to the small error state.
ESKF vs. Other Kalman Filter Variants
A technical comparison of the Error State Kalman Filter (ESKF) against other prominent Kalman filter variants, highlighting key architectural differences, performance characteristics, and suitability for robotics and state estimation tasks.
| Feature / Metric | Error State Kalman Filter (ESKF) | Extended Kalman Filter (EKF) | Unscented Kalman Filter (UKF) | Particle Filter (PF) |
|---|---|---|---|---|
Core Estimation Principle | Estimates the error in a nominal state, then corrects it. | Estimates the full state directly via local linearization of nonlinear models. | Estimates the full state via deterministic sampling (unscented transform). | Estimates the full state posterior via a set of random samples (particles). |
Handling of Nonlinearities | Local linearization (1st-order Taylor) | Deterministic sampling (typically 2nd-order accuracy) | Non-parametric; handles arbitrary nonlinearities | |
Assumed Noise Distribution | Gaussian | Gaussian | Gaussian | Arbitrary (non-Gaussian) |
Computational Complexity | Low to Moderate | Moderate (requires Jacobian calculation) | Moderate (scales with state dimension) | High (scales with particle count) |
Numerical Stability for Attitude (SO(3)) | High (operates on minimal tangent space) | Low (prone to singularities, normalization issues) | Moderate (better than EKF, but state may leave manifold) | High (can embed manifold constraints) |
Typical Use Case in Robotics | Visual-Inertial Odometry (VIO), LiDAR-Inertial Odometry (LIO) | Basic sensor fusion, GPS-INS integration | Radar tracking, moderately nonlinear systems | Global localization, SLAM with multi-modal distributions |
Inherent Support for Manifold States (e.g., Rotations) | ||||
Ease of Implementation | Moderate (requires careful error-state definition) | Moderate (requires Jacobian derivation) | Moderate (library-dependent) | High (conceptually simple, tuning is hard) |
ESKF Applications and Use Cases
The Error State Kalman Filter's unique architecture—estimating errors on a nominal state—makes it the preferred choice for high-performance, real-time systems where numerical stability and efficient handling of nonlinearities are paramount.
Robotic Attitude & Heading Reference Systems (AHRS)
The ESKF is the de facto standard for fusing inertial measurement unit (IMU) data (gyroscopes, accelerometers, magnetometers) to estimate a robot's 3D orientation (roll, pitch, yaw). Its error-state formulation provides critical advantages:
- Numerical Stability: By keeping the orientation quaternion in the nominal state, it avoids singularities and normalization issues common in direct quaternion filters.
- Efficient Linearization: The error state for small-angle rotations is approximately linear and Gaussian, making the Kalman update highly accurate and computationally efficient.
- Bias Estimation: It seamlessly estimates and corrects for slowly varying sensor biases (gyro bias, accelerometer bias) within the error state. This application is foundational for drones, humanoid robots, and autonomous vehicles that require a stable 'up' vector and heading.
Visual-Inertial Odometry (VIO) & SLAM
In Visual-Inertial Odometry (VIO) and Simultaneous Localization and Mapping (SLAM) systems, the ESKF provides the backbone for tightly-coupled sensor fusion. It fuses high-frequency IMU predictions with lower-frequency, absolute visual constraints from a camera.
- IMU Propagation: The IMU's linear acceleration and angular velocity measurements propagate the nominal state (pose, velocity) via direct integration.
- Error-State Kalman Update: The difference between visually estimated features and those predicted by the nominal state generates a measurement residual. This residual updates the error state (small corrections to pose, velocity, and sensor biases).
- Drift Correction: The filter's structure allows visual loop closures or GPS measurements to be incorporated as direct corrections to the error state, efficiently correcting long-term drift inherent in dead reckoning. This is central to autonomous navigation in GPS-denied environments.
Autonomous Vehicle Localization
Self-driving cars use a multi-sensor ESKF to achieve centimeter-level localization by fusing data from:
- Inertial Navigation System (INS): Provides high-frequency pose and velocity estimates.
- Global Navigation Satellite System (GNSS): Provides absolute, globally-referenced position, but is subject to dropout and multipath error.
- LiDAR Odometry / Visual Odometry: Provides relative motion estimates and acts as a bridge during GNSS outages.
- Wheel Odometry: Provides a direct measure of longitudinal velocity. The ESKF's strength here is managing heterogeneous sensor rates and uncertainties. The nominal state is propagated by the INS, while the error state absorbs corrections from all other sensors. Its formulation handles the nonlinear geometry of 3D orientation smoothly, which is critical for vehicle dynamics on sloped or banked roads.
Precision Aerospace & Satellite Navigation
In aerospace applications like spacecraft attitude determination and high-altitude aircraft navigation, the ESKF is favored for its robustness and precision.
- Star Tracker Fusion: The filter combines gyroscope data with highly accurate but low-frequency star tracker measurements. The error state formulation cleanly handles the large time gaps between star tracker updates.
- Handling Quaternion Constraints: Representing the full attitude quaternion in the nominal state and only small-angle errors in the filter state avoids the gimbal lock and parameterization issues of Euler angles, while being more efficient than a direct quaternion Kalman filter.
- Vibration and Dynamic Stress: The algorithm's numerical stability is crucial in environments with high vibration and dynamic stress, where linearization points can change rapidly. The error state, being small by definition, remains well within the region where linearization is valid.
Legged Robot State Estimation
Dynamic legged robots (e.g., humanoids, quadrupeds) present extreme challenges for state estimation due to violent contact dynamics, slippage, and high-frequency impacts. An ESKF is often deployed in a contact-aided configuration.
- IMU-Centered Nominal State: The torso pose and velocity are propagated using the IMU.
- Leg Kinematics as Measurements: The filter uses forward kinematics from joint encoders and an assumed contact state to estimate the foot's position relative to the torso. When a foot is judged to be in stable contact with the ground, this provides a pseudo-measurement of the torso's position and orientation.
- Error-State Correction: The difference between the IMU-propagated state and the kinematics-inferred state updates the error state. This tightly couples proprioception with inertia, creating a drift-free estimate of the robot's base state that is resilient to temporary slippage and sensor shock, which is vital for balance and locomotion controllers.
Comparison to Other Filters
The ESKF's value is clarified by contrasting it with other common filters in the state estimation hierarchy:
- vs. Extended Kalman Filter (EKF): The EKF linearizes the full system dynamics and measurement models around the current state estimate. For attitude (represented by quaternions), this linearization can be complex and less numerically stable. The ESKF linearizes only the simpler error dynamics, which are inherently more linear.
- vs. Unscented Kalman Filter (UKF): The UKF uses sigma points to propagate statistics through nonlinear models, often more accurately than the EKF. However, it is more computationally expensive. The ESKF offers a middle ground: near-UKF accuracy for attitude problems with computational cost closer to the EKF.
- vs. Complementary Filter: A simple complementary filter is a lightweight frequency-domain fusion method. The ESKF is its probabilistic, optimal generalization, providing not just a state estimate but also a full covariance matrix representing uncertainty, enabling sensor validation and autonomous confidence estimation. This makes the ESKF the engineering sweet spot for complex, real-time robotic systems.
Frequently Asked Questions
The Error State Kalman Filter (ESKF) is a cornerstone algorithm in high-performance state estimation for robotics and autonomous systems. These questions address its core mechanics, advantages, and practical applications.
An Error State Kalman Filter (ESKF) is a variant of the Kalman filter that estimates the small error or deviation in a nominal state rather than the full state itself, which is particularly advantageous for handling the nonlinearities inherent in 3D orientation (attitude) estimation.
In an ESKF, the system maintains two parallel representations:
- Nominal State: A straightforward, often nonlinear, integration of motion (e.g., integrating gyroscope data for orientation).
- Error State: A small, linear perturbation around the nominal state, which is estimated by the Kalman filter.
The filter's core loop involves:
- Predicting the nominal state forward using inertial measurements.
- Predicting the statistics (mean and covariance) of the error state.
- Updating the error state estimate using other sensor observations (e.g., camera, GPS).
- Injecting the corrected error back into the nominal state and resetting the error state to zero. This separation allows the filter to operate on a state that is always small and locally linear, even when the overall system dynamics (like 3D rotation) are highly nonlinear.
Enabling Efficiency, Speed & Accuracy
Intelligent Analysis, Decision & Execution
We build AI systems for teams that need search across company data, workflow automation across tools, or AI features inside products and internal software.
Talk to Us
Search across company data
Give teams answers from docs, tickets, runbooks, and product data with sources and permissions.
Useful when people spend too long searching or get different answers from different systems.

Automate internal workflows
Use AI to route work, draft outputs, trigger actions, and keep approvals and logs in place.
Useful when repetitive work moves across multiple tools and teams.

Add AI to products and internal tools
Build assistants, guided actions, or decision support into the software your team or customers already use.
Useful when AI needs to be part of the product, not a separate tool.
Related Terms
The Error State Kalman Filter (ESKF) is a core technique within a broader ecosystem of algorithms for robust state estimation. These related concepts define the mathematical frameworks, alternative methods, and practical systems that surround the ESKF.
Kalman Filter
The Kalman filter is the foundational optimal recursive algorithm for state estimation in linear dynamic systems. It operates in a predict-update cycle: predicting the state forward using a process model, then updating the prediction with a new measurement via a weighted average (the Kalman gain). The ESKF is a direct variant, inheriting this core structure but applying it to the error state rather than the full state, which provides superior handling of nonlinearities inherent in attitude representation.
State Estimation
State estimation is the overarching problem of inferring the internal, often hidden, variables of a dynamic system from a sequence of noisy sensor observations. Key state variables for robotics include:
- Pose (position and orientation)
- Velocity and angular velocity
- Sensor biases (e.g., IMU accelerometer bias)
The ESKF provides a specific solution to this problem by estimating the error between a nominal state (propagated by inertial integration) and the true state, which is then used to correct the nominal state.
Sensor Fusion
Sensor fusion is the algorithmic combination of data from multiple, disparate sensors to produce a state estimate that is more accurate, complete, and reliable than any single sensor could provide. The ESKF is a fusion engine commonly used for:
- Visual-Inertial Odometry (VIO): Fusing camera images with IMU data.
- LiDAR-Inertial Odometry (LIO): Fusing 3D LiDAR scans with IMU data.
- GPS-INS Integration: Correcting inertial drift with global positioning signals. It exemplifies a tightly-coupled fusion approach where raw sensor residuals are processed within a unified probabilistic framework.
Unscented Kalman Filter (UKF)
The Unscented Kalman Filter (UKF) is another nonlinear estimation algorithm designed to address the limitations of the standard Extended Kalman Filter (EKF). While the EKF uses first-order linearization, the UKF uses a deterministic sampling technique called the unscented transform to propagate a set of sigma points through the true nonlinear functions. Compared to the ESKF, the UKF operates on the full state and can better handle severe nonlinearities, but the ESKF's error-state formulation often provides greater numerical stability for attitude estimation on embedded systems.
Inertial Navigation System (INS)
An Inertial Navigation System (INS) is a self-contained dead-reckoning system that uses accelerometers and gyroscopes to track position, velocity, and orientation by double-integrating acceleration and integrating angular rate. A standalone INS suffers from unbounded drift due to sensor bias and noise integration. The ESKF is the central algorithm in a Strapdown INS, where it fuses the drifting inertial predictions with absolute measurements from other sensors (e.g., GPS, cameras) to produce a bounded-error navigation solution.
Covariance Matrix
The covariance matrix is a square matrix that quantifies the uncertainty (variance) of each state variable and the correlations between them. In the ESKF, two key covariance matrices are maintained:
- Process noise covariance (Q): Models the uncertainty in the system's motion model.
- Measurement noise covariance (R): Models the uncertainty in the sensor observations. The ESKF uses these matrices to compute the optimal Kalman gain, which determines how much to trust a new measurement versus the prior prediction. The evolution of the error-state covariance matrix is central to the filter's performance.

About the author
Prasad Kumkar
CEO & MD, Inference Systems
Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.
His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.
Partnered with leading AI, data, and software stack.
How We Work
Custom AI workflows for your Business
One-fit-all AI don't work for modern businesses. At Inferensys, we aim to understand your business & custom requirements; which we use to define most efficient agentic workflows, the data, and the tools for your business.
01
Review the use case
We understand the task, the users, and where AI can actually help.
Read more02
Pick the right approach
We define what needs search, automation, or product integration.
Read more03
Build the first useful version
We implement the part that proves the value first.
Read more04
Improve from there
We add the checks and visibility needed to keep it useful.
Read moreThe first call is a practical review of your use case and the right next step.
Talk to Us