
Working with Moroccan clients? If you’re a Spanish company operating in sectors like engineering, technology, construction, or energy, understanding Morocco’s withholding tax rules is critical to protecting your profits.
This guide breaks down when Morocco can — and cannot — apply withholding tax to your invoice, based on the Morocco–Spain Tax Treaty (1978). We’ll walk you through real-world examples and explain how to avoid double taxation with clarity.
Table of Contents
Understanding the Morocco–Spain Tax Treaty
The Double Taxation Agreement (DTA) signed between Morocco and Spain in 1978 governs how income is taxed when Spanish companies do business in Morocco.
There are two key articles to understand:
- Article 7 – Covers business profits and applies when there’s no “permanent establishment” (PE) in Morocco.
- Article 12 – Covers royalties, which can be taxed in Morocco at 10% withholding tax.
Knowing which article applies to your situation makes the difference between keeping 100% of your invoice — or losing 10% to Moroccan tax authorities.
When Withholding Tax Does NOT Apply
Short Missions = No Tax
If your company is only providing temporary services in Morocco, and you:
- Don’t rent an office
- Don’t hire local staff
- Don’t store tools or materials in the country
Then, you do not create a permanent establishment. According to Article 7, Morocco cannot tax your income — it’s only taxed in Spain.
Result: Full invoice paid, no Moroccan withholding.
When Withholding Tax DOES Apply
Intellectual Work = Taxable
When your company delivers value through knowledge, your income often qualifies as a royalty under Article 12, which does allow Morocco to take 10% withholding tax.
Examples include:
- Technical reports and studies
- Software licences
- Training that transfers know-how
Result: 10% withheld in Morocco, credited later in Spain (no double taxation).
4 Real-Life Case Studies
Case 1: Short Engineering Mission — No Tax
A Spanish maintenance company sends two engineers to a Moroccan factory for 5 days. They:
- Don’t rent premises
- Don’t hire staff
- Don’t store equipment
Analysis: This is a temporary service, not a PE.
Result: No Moroccan tax; full income taxed in Spain under Article 7.
Case 2: Technical Study — 10% Tax
A Spanish engineering firm creates a full solar energy feasibility report for a Moroccan client, including calculations and diagrams.
Analysis: This is intellectual property — the client can reuse it.
Result: 10% withholding tax in Morocco under Article 12; Spain gives credit.
Case 3: Software License — 10% Tax
A Spanish tech company licenses its project management platform to a Moroccan firm.
Analysis: Payment is for the right to use software, which is a royalty.
Result: 10% withholding tax applies under Article 12.
Case 4: Training and Know-How — Mixed Outcomes
A Spanish renewable energy firm sends specialists to train Moroccan engineers.
- If they only show how to operate machinery → Normal service, no tax.
- If they transfer technical methods the engineers can use later → Royalty, 10% tax.
Rule: If knowledge is reusable, it’s a royalty.
How to Stay Compliant: Best Practices
To make sure your company doesn’t overpay or get penalized, follow these steps:
1. Classify Your Work Correctly
- Don’t call a service a “study” unless it really is.
- Label software payments and training properly.
2. Keep Tax Residency Certificates Updated
- Always provide a Spanish tax residence certificate to Moroccan clients.
3. Get Withholding Certificates from Morocco
- If 10% is withheld, ask for a certificate for your Spanish accountant.
4. Claim Tax Credit in Spain
- Under Spanish law, tax withheld in Morocco is fully credited to avoid double taxation.
5. Consult an Expert When in Doubt
- Cross-border tax is complex. Talk to professionals who understand both systems.
FAQs: Morocco–Spain Withholding Tax
Is every service taxed in Morocco?
No. Only services that involve royalties or knowledge transfer are subject to Moroccan withholding tax.
What if I only visit Morocco for a few days?
Short visits with no permanent presence in Morocco are not taxable under Article 7.
Can I recover the 10% tax?
You can’t recover it directly, but Spain gives you a tax credit for that exact amount.
What happens if I misclassify the work?
You may be overcharged or even penalized. Proper classification protects your business.
Conclusion: Protecting Your Business
The Morocco–Spain Tax Treaty is a powerful tool — but only if applied correctly.
Key takeaway:
- Services = Article 7 → No Moroccan tax
- Royalties = Article 12 → 10% Moroccan tax, credited in Spain
Before invoicing, be precise about the nature of your work. Keep certificates. And most importantly, don’t assume — verify.
Need Help? Contact NEO Expertise
Navigating international tax rules shouldn’t be guesswork. At NEO Expertise, we specialize in cross-border tax compliance and can help you:
- Classify your services
- Prepare the right documents
- Avoid double taxation
Contact NEO Expertise today to protect your revenue and operate with confidence.

Brahim Rami | Member of institute of chartered accountants in Morocco
He is a CPA and tax advisor, founder of NeoExpertise.net, a Legal and Tax firm helping foreign companies with business setup, due diligence, payroll, and tax compliance in Morocco and Africa.




