Federated Averaging (FedAvg) is the foundational federated learning algorithm where a central server initializes a global model, distributes it to participating clients, and then aggregates the locally trained model weights by computing a weighted average to produce an improved global model. This iterative process allows collaborative learning across decentralized datasets without ever centralizing or exposing the raw, privacy-sensitive data residing on each client.
Glossary
Federated Averaging (FedAvg)

What is Federated Averaging (FedAvg)?
The core optimization algorithm that enables decentralized model training by mathematically aggregating locally computed parameter updates into a single, robust global model without exposing raw data.
The algorithm's core innovation is reducing communication rounds by having clients perform multiple local stochastic gradient descent (SGD) steps before sending updates. The server then fuses these updates proportionally to each client's dataset size, effectively optimizing a global objective while tolerating non-IID data distributions and limited client availability common in cross-silo healthcare networks.
Key Characteristics of FedAvg
Federated Averaging (FedAvg) is defined by a specific operational loop that balances local computation with global synchronization. The following characteristics define its behavior in production multi-institutional networks.
Local Stochastic Gradient Descent (SGD)
Unlike traditional distributed training that requires constant communication, FedAvg allows each client to perform multiple local epochs of training on its private data before communicating. This reduces communication rounds by 10–100x compared to federated SGD. The client computes weight updates by minimizing the local loss function on its own non-IID data partition, producing a partially optimized model state that captures site-specific statistical patterns before aggregation.
Weighted Parameter Averaging
The central server constructs the new global model by computing a weighted arithmetic mean of the local model parameters. The weighting coefficient is typically proportional to the number of training samples each client used, ensuring that clients with larger datasets exert proportionally greater influence on the global consensus. This aggregation step is mathematically equivalent to minimizing a global loss function that is the weighted sum of local empirical risks.
Client Selection and Fraction Control
In each communication round, the server selects a fraction C of available clients to participate, rather than waiting for all clients to respond. This partial participation mechanism is critical for scaling to cross-device deployments with unreliable endpoints. The selection fraction introduces a trade-off: lower C values reduce communication cost but increase variance in the aggregated update, potentially slowing convergence or introducing bias toward the selected subset.
Non-IID Robustness Limitations
FedAvg exhibits convergence instability when local data distributions are statistically heterogeneous. If client datasets are highly skewed—differing in label distribution, feature distribution, or concept drift—the local optima can diverge significantly. Averaging divergent weight vectors can produce a global model that performs poorly on any individual client. This phenomenon, known as weight divergence, motivates advanced variants like FedProx and SCAFFOLD that add corrective terms to local objectives.
Communication Efficiency Profile
FedAvg reduces communication by a factor proportional to the number of local epochs performed between synchronization rounds. The total communication cost per round is 2 × model size per participating client (upload and download). For large neural networks, this bandwidth requirement can become prohibitive. Compression techniques such as gradient quantization, sparsification, and structured updates are often layered on top of FedAvg to further reduce the bitrate without sacrificing convergence guarantees.
Privacy-By-Architecture Guarantee
FedAvg provides a foundational privacy property: raw data never leaves the client device. Only model weight updates are transmitted. However, these weight updates are not inherently private—gradient leakage attacks can reconstruct training samples from shared parameters. Production deployments therefore combine FedAvg with differential privacy (adding calibrated noise to updates) and secure aggregation (encrypting individual contributions so the server only sees the sum) to achieve formal privacy guarantees.
Frequently Asked Questions
Clear, technical answers to the most common questions about the foundational Federated Averaging (FedAvg) algorithm, its mechanisms, and its role in privacy-preserving collaborative machine learning.
Federated Averaging (FedAvg) is the foundational optimization algorithm for federated learning that constructs a global machine learning model by iteratively averaging the locally computed model weight updates from multiple decentralized clients, without ever accessing their raw data. The process works in communication rounds: a central server initializes a global model and distributes it to a selected subset of participating clients. Each client trains the model on its local private dataset for a fixed number of local epochs, producing an updated set of model weights. These local weight updates—not the training data—are transmitted back to the central server. The server then computes a weighted average of all received updates, typically weighted by the number of local training samples each client used, to produce a new global model. This cycle repeats for many rounds until the global model converges. The core insight of FedAvg is that by increasing the amount of local computation per round (performing multiple local SGD steps), the algorithm reduces the number of communication rounds required for convergence, making it practical for bandwidth-constrained environments like mobile devices and hospital networks.
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
Explore the foundational algorithms, security protocols, and optimization strategies that surround and extend the core Federated Averaging (FedAvg) algorithm in privacy-preserving machine learning.
Secure Aggregation
A cryptographic protocol that ensures the central server in a FedAvg round can only compute the sum of model updates, not inspect individual client contributions. This prevents the server from performing gradient leakage attacks to reconstruct private training data. Secure aggregation typically relies on Shamir's secret sharing and pairwise masking, allowing the global model to benefit from all clients while mathematically guaranteeing that no single participant's update is exposed in plaintext.
Non-IID Data Handling
The primary failure mode of vanilla FedAvg. When client data is statistically heterogeneous—meaning local distributions differ in label balance, feature distribution, or concept—simple weight averaging can lead to severe client drift and a degraded global model. Strategies to mitigate this include: - FedProx for constrained local updates - SCAFFOLD for variance reduction using control variates - Personalized Federated Learning (pFL) to forgo a single global model entirely
Byzantine Fault Tolerance (BFT)
Standard FedAvg assumes all clients are honest. In adversarial settings, a single malicious client can submit arbitrary updates to poison the global model. Byzantine-robust aggregation replaces simple averaging with robust statistics like coordinate-wise median, geometric median, or Krum. These operators filter out outliers before aggregation, ensuring the global model remains correct even when a fraction of clients are actively malicious or have suffered catastrophic hardware failure.
Differential Privacy (DP)
FedAvg shares model weights, not raw data, but weights alone can leak information through membership inference or model inversion attacks. Differential Privacy provides a formal guarantee by adding calibrated Gaussian noise to the aggregated update before applying it to the global model. The privacy budget, controlled by the parameter epsilon (ε), quantifies the maximum information leakage risk, allowing institutions to provably bound the privacy loss incurred during each federated training round.
Cross-Silo vs. Cross-Device Topologies
FedAvg behaves differently depending on the deployment topology. Cross-silo FL involves a small number (2-100) of reliable institutional clients (e.g., hospitals) that participate in every round, making synchronous FedAvg straightforward. Cross-device FL involves millions of unreliable edge devices (e.g., smartphones) with intermittent connectivity. This requires FedAvg variants that handle client dropout, stragglers, and limited upload bandwidth, often selecting only a random subset of available clients per round.

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