Karachi, Pakistan - August 20, 2018: Heavy traffic is moving over the shahrah-e-Pakistan in the locality of Laloo Khet (aka Liaquatabad), Karachi. It is one of the leading avenues which leads towards the super Highway, connecting Karachi and Hyderabad. Photo credit: Bashir Osman's Photography via Getty images.
Using machine learning to strengthen tax compliance: Lessons from Pakistan
As tax administrations increasingly adopt machine learning and AI tools to improve compliance, Pakistan’s tax system offers practical lessons in compliance risk management. By integrating AI into existing administrative workflows, Pakistan’s CRM system is improving audit targeting, supporting risk-based decision-making, and complementing - not replacing - oversight from experienced field officers.
This post is part of a new series on intelligent taxation and AI, which brings together evidence, policy lessons, and challenges of using AI to strengthen tax administration. Explore the Tax for Growth initiative’s new policy toolkit: Harnessing AI and data for tax administration, which synthesises lessons for governments and Commonwealth tax administrators.
Tax administrations across developing countries face a common challenge: how to improve compliance despite large taxpayer bases, imperfect information, and limited administrative capacity.
By enabling electronic filing and expanding access to third-party data, the digitalisation of tax systems has created new opportunities. Machine learning and AI tools now allow tax administrations to process large volumes of data systematically, support risk-based decision-making, and help focus limited enforcement resources in areas where the likelihood of non-compliance is highest.
However, for developing countries in particular, the key question is not whether artificial intelligence can be deployed, but whether it can be integrated in a way that improves enforcement outcomes while remaining institutionally feasible, fair, and credible.
Pakistan’s tax administration challenge
Examining Pakistan’s tax system can help answer this question, especially since the country shares many of the structural challenges faced by other low- and middle-income countries.
While the number of registered taxpayers has grown over time, effective compliance remains uneven. A large share of economic activity takes place outside the formal sector, income is often fragmented across sources, and reliable third-party information is limited. As a result, declared tax bases frequently fall short of underlying economic activity, creating persistent gaps between potential and realised revenue.
Historically, tax enforcement in Pakistan has relied heavily on withholding mechanisms and static selection of financial transactions for audit based on predefined risk parameters. Withholding taxes - including transactional withholding on the sale or purchase of movable and immovable assets - account for roughly 23% of direct tax collection (excluding withholding taxes on salaries). While these mechanisms secure revenue at the source, they provide limited insight into underlying compliance behaviour and generate weak signals for identifying high-risk cases.
At the same time, audit capacity remains constrained relative to the taxpayer base. In regional tax offices, the ratio of taxpayers to officers ranges between approximately 15,000 and 30,000 to one; even in large corporate tax offices, the ratio is close to 1,700 to one. These structural constraints make it difficult to conduct detailed, case-by-case reviews at scale. Internal survey evidence further suggests that officers may spend up to 60% of their time on non-audit administrative tasks, reducing the time available for substantive compliance analysis.
Together, these factors limit the ability to deploy audits strategically, often resulting in broad screening exercises or narrowly targeted actions that may miss significant sources of non-compliance.
Introducing machine learning in Pakistan’s compliance toolkit
The recognition of these constraints has increasingly shifted attention towards strategic risk-based enforcement. The objective has not been to expand the number of audits, but to improve their quality and effectiveness, reducing unnecessary interactions with compliant taxpayers while increasing the likelihood that audits uncover meaningful discrepancies and deter non-compliance. In this context, the gradual introduction of machine learning and AI tools has been motivated by a practical need: to use existing data more effectively to guide enforcement decisions in a complex and resource-constrained environment.
Machine learning in Pakistan’s tax administration has been introduced as part of Pakistan’s broader move towards compliance risk management (CRM). Rather than treating audits as isolated enforcement actions, the CRM framework focuses on four core compliance risks: registration, timely filing, accurate reporting, and correct tax payment.
Initial applications have focused on large taxpayers where revenue concentration is high, and enforcement capacity must be deployed carefully. Using integrated income tax, sales tax, and customs data, the system identifies inconsistencies across filings, such as mismatches between reported sales and corresponding income declarations. Instead of relying on single red flags, cases are ranked based on patterns of risk across multiple indicators, many of which are fed into the system with feedback from experienced field officers.
Importantly, the models generate prioritisation signals rather than automatic audit decisions. These risk rankings are embedded into operational dashboards used by field officers, and human oversight remains central to the process: officers review high-risk cases, assess materiality, and determine the appropriate compliance response. Machine learning therefore functions as a decision support tool within existing administrative processes, strengthening risk-based enforcement while preserving accountability and discretion.
Supporting compliance risk management at the field level
A key objective of Pakistan’s CRM system is not only to improve risk identification, but to make enforcement more manageable and effective for officers working within defined jurisdictions. Rather than manually examining large volumes of individual cases, officers can view sector-level summaries for their assigned tax office and year, see where compliance risks are concentrated, how taxpayers are distributed across risk categories, and identify which risk groups are driving anomalies within a sector.
This allows enforcement attention to be directed strategically, rather than through case-by-case scrutiny. By prioritising the most material and persistent anomalies, the CRM system effectively shifts enforcement from reactive case selection to proactive risk management, conserving audit capacity while still improving compliance outcomes.
Field officers gain a clearer picture of compliance behaviour within their jurisdiction, are better equipped to allocate time and effort, and can focus audits on cases where the likelihood of generating revenue by capturing evasion is highest. This operational integration is central to how AI tools in Pakistan are complementing rather than replacing traditional enforcement, strengthening the overall effectiveness of the tax administration.
Evaluating the impact of machine learning-based risk management
The CRM system is also being used for preventive compliance interventions, with measurable early results. In sales tax, the system classified approximately 13,000 corporate taxpayers into high-, medium-, and low-risk categories based on their monthly returns. From this pool, around 9,000 taxpayers were randomly selected across risk groups and sent targeted electronic nudges highlighting specific risk flags in their filings.
Six months after the intervention, administrative data indicated that nearly 10% of nudged taxpayers in the high- and medium-risk categories increased their tax payments by approximately 30% compared to the same period in the previous year.
On the income tax side, CRM dashboards provide officers with real-time risk updates rather than static annual criteria. An initial exercise involving approximately 50 large taxpayers assessed whether model-identified risks aligned with substantive audit potential, thereby strengthening confidence in the system’s operational relevance. While post-nudge behaviour is still being monitored, early results suggest that risk scoring guided by machine learning can improve compliance outcomes without immediately resorting to audit.
Implications for tax administration reform in Pakistan
Pakistan’s experience with machine learning in tax administration illustrates both the promise of AI and the discipline required to deploy these tools effectively. Rather than treating it as a substitute for institutional capacity, the CRM framework demonstrates how data-driven risk assessment can be used to prioritise scarce enforcement resources and encourage compliance through proportionate interventions. Importantly, the focus has been on integrating machine learning into existing administrative workflows, supporting officers, informing compliance strategies, and enabling continuous monitoring, rather than automating enforcement.
A key lesson is that the value of machine learning lies not only in audit selection, but in expanding the range of compliance tools available to tax authorities. In many instances, potential issues can be addressed through clarification requests, nudges, or corrective filings without resorting to a full audit. Risk scores have been used to guide these nudges and improve filing accuracy. Embedding evaluation into these interventions has been critical to ensure that learning continues as systems evolve and that policy decisions remain grounded in evidence.
Scaling AI in tax administration across developing countries
Future reforms could expand AI into real-time compliance support at the point of filing tax returns. By benchmarking reported ratios against sectoral norms, the system could generate immediate soft prompts when anomalies arise, encouraging corrective action before enforcement is required. Integrating cross-tax and third-party data into unified risk profiles would allow nudges to be generated proactively, subject to officer approval. Such developments could further reduce compliance costs while improving accuracy and timeliness.
For other developing countries considering similar reforms, Pakistan’s experience highlights several broader implications. Investments in data and analytics are most effective when paired with institutional safeguards, human oversight, and a clear compliance strategy. Machine learning tools should be designed to be interpretable, adaptive, and closely linked to operational needs at the field level. Above all, AI should be seen as part of a long-term process of strengthening state capacity - one that requires experimentation, evaluation, and sustained institutional commitment.