Law 82-21 lets any person or company in Morocco generate electricity for its own use. Grid-connected installations fall under declaration below 11 kW, connection approval from 11 kW to 5 MW, or authorisation from 5 MW. Surplus sold to the grid is capped at 20% of annual production, paid 18 to 21 centimes per kWh at medium voltage and above.
When decree 2-25-100 appeared in the Bulletin Officiel of 9 March 2026, the press read it as the moment solar self-consumption was finally unlocked. The decree did set out the procedure for the three regimes, and it has been in force since 9 June 2026.
For an industrial energy user, the deciding questions sit elsewhere: which regime applies and where its threshold is written, how much surplus can be sold and at what price, and which texts are still missing. Here is how the framework actually works.
What does law 82-21 allow?
It allows production for the producer’s own needs, and nothing more. The law covers every source, voltage level and capacity, but defines the self-generator as a person producing electricity exclusively for its own consumption, who owns the installation or holds the right to dispose of it. Every filing under the decree carries a commitment not to transfer any of the output to another party.
A developer that builds a plant to sell power to a factory is not a self-generator but an operator under law 13-09. And the surplus has one possible buyer, the grid operator concerned.
Which regime applies to my installation?
Capacity and connection decide, and the two thresholds do not carry the same legal weight.
| Regime | Installation | Filed with | Written in |
|---|---|---|---|
| Declaration | Off-grid, any capacity | Energy ministry’s local services | Law, article 3 |
| Declaration | Below 11 kW, low voltage | Distribution network operator | Decree, article 5 |
| Connection approval | 11 kW to 5 MW, low or medium voltage | Distribution network operator | Decree for 11 kW, law for 5 MW |
| Authorisation | 5 MW and above, medium to very high voltage | Energy ministry’s local services | Law, article 6 |
The 11 kW line exists only in decree 2-25-100: the law refers to a threshold set by regulation, so another decree can move it. The 5 MW line is in the law itself, and changing it means amending the law. The law also adds up the units installed on one site, so a 6 MW project cannot be filed as two approvals of 3 MW.
On paper the approval takes 30 days from a complete file. That excludes up to 15 days to check hosting capacity and the grid operator’s technical study, paid for by the applicant and due within three months, extendable by 30 days. Capacity is reserved in order of filing, within the hosting capacity the ANRE approves each year: 691 MW of solar on the distribution networks for 2026, a cumulative figure shared with projects under law 13-09. Building or operating without approval or authorisation carries a fine of MAD 100,000 to 1 million.
Can I sell my surplus, and how much?
Up to 20% of annual production, at a price that exists for medium voltage and above, not yet for low voltage. The cap is in article 12 of the law, the price in ANRE decision 04/26: 18 centimes per kWh off-peak and 21 centimes at peak, for a first period from 1 March 2026 to 28 February 2027.
Three details change the arithmetic. Peak means 17:00 to 22:00 from October to March and 18:00 to 23:00 from April to September, in GMT, hours in which a solar plant produces little, so the working figure for photovoltaic surplus is 18 centimes. The tariff is stated excluding taxes, the system-services charge and environmental attributes, and nothing is netted from it: ANRE decision 02/24 exempts the surplus sold from the transmission tariff, the system-services charge and losses, and decision 02/25 charges nothing on energy consumed on site. And it is set at the value in force when the convention with the grid operator is signed, then revised in line with the average regulated supply tariff.
Surplus is metered monthly and settled against the 20% cap at year end. Article 12 allows the cap to be revised at the self-generator’s request, under conditions to be set by regulation. That text does not exist yet.
A worked example
Take a factory connected at medium voltage that plans a 4.9 MW solar plant on its own site, with an assumed output of 8,000 MWh a year.
At 4.9 MW the project stays in the connection approval regime. An installation of exactly 5 MW fits the wording of both regimes, a good reason to stay clear of the line.
The surplus cap is 20% of 8,000 MWh, or 1,600 MWh. Assume output is spread evenly over the year and working days absorb all of it. A site that stops on Sundays and for three weeks in summer has 70 days without load: 19% of output, about 1,534 MWh, just inside the cap. At 18 centimes, that is about MAD 276,000 a year.
Run the same site five days a week and the idle days rise to 119, or 33% of output: about 2,608 MWh. The first 1,600 MWh earn MAD 288,000. The remaining 1,008 MWh fall outside the cap and outside the tariff.
A kilowatt-hour consumed on site is worth the tariff it displaces on the bill. A kilowatt-hour exported is worth 18 centimes and, beyond the cap, nothing.
What is still missing?
Most of what would make a project flexible, as of November 2026.
| Item | Legal basis | Status, November 2026 |
|---|---|---|
| Revision of the 20% cap | Law, article 12 | Draft deferred in October 2025; announced for 2027 |
| Surplus tariff at low voltage | Law, article 12 | Not set; left by the ANRE to a later decision |
| Storage | Law, article 15 | No text published by end October 2026 |
| Curtailment threshold | Law, article 32 | No text published by end October 2026 |
| Distribution-services contribution | Law, article 13 | Named by the ANRE as its next step in February 2026; no decision published |
| Certificates of origin | Decree 2-24-761 | In force; national registry not yet in service |
| Filing forms | Decree 2-25-100, articles 1 to 21 | Left to a ministerial order; none published by end October 2026 |
| Online filing platform | Decree 2-25-100, article 25 | Opening date left to a ministerial order; none published by end October 2026 |
Smart metering is the exception: decree 2-24-804 fixed the meter’s functions in 2024, the law reserves its installation to the grid operator, and decision 04/26 adds a second meter for on-site generation.
The law gave the government four years from its publication on 27 February 2023 to issue the implementing texts: until 27 February 2027, the day before the first surplus tariff period is due to close.
How is this different from buying renewable power?
Self-generation and third-party supply are two laws with two licensing routes. Under law 13-09 as amended by law 40-19, an operator, necessarily a private-law legal entity, produces renewable electricity and supplies it under contract to consumers connected to the national grid. The consumer buys electricity; the operator holds the authorisation, required from 2 MW (a prior declaration below that), which for a medium-voltage plant runs through the regional investment procedure of law 47-18 (see how CRI approval works).
An operator’s surplus carries the same 20% cap, written in article 26 of law 13-09, and decision 04/26 pays it at the same tariff. Use of the grid is charged at the tariffs the ANRE set from 1 March 2026: 6.85 centimes per kWh on the transmission network, 6.07 on medium-voltage distribution and 6.81 for system services, plus losses compensated in kind, capped at 6% on transmission and 4.5% at medium voltage.
Medium-voltage access for operators is itself unfinished: a draft decree replacing decree 2-15-772 was in public consultation in June 2026, and the ministry lists it among the texts planned for 2027.
What to do now
Size the plant to the load, not to the roof. Map the hours when the site does not consume before fixing capacity. With a 20% cap and an 18 centime export price, every oversized kilowatt is a cost.
Decide early which side of 5 MW the project sits on. Below it, the counterparty is the distribution network operator. At or above it, the file goes to the ministry, and generation on a separate site becomes possible in principle: article 7 still leaves to regulation the capacity that separates medium-voltage from high-voltage access.
Treat the surplus price as a contract term. It is fixed when the convention is signed, and the first period ends on 28 February 2027 unless the ANRE Council extends it. Storage and a higher cap have no implementing text: sensitivity only.
Check the status of plants already running. Article 33 gave existing installations 18 months from the law’s entry into force to apply for regularisation. Counted from 27 May 2023, three months after publication, that period ended on 27 November 2024, before any procedure existed. Article 36 brings provisions that depend on implementing texts into force when those texts are published, and decree 2-25-100 says nothing about existing plants: the starting date is a point to confirm with the administration.
Keep the evidence of origin. The two real drivers of these projects are the cost of electricity and the carbon content of exports, which we cover in the EU carbon border mechanism and Moroccan exporters. Certificates of origin will be requested through a national registry not yet in service, on monthly production, consumption and injection records. Carbon credits are a separate question, covered in Morocco’s draft carbon market law.



