Assessment of the Hosting Capacity of the Moroccan Electricity Grid for the Integration of Renewable Energies

Original scientific paper

Journal of Sustainable Development of Energy, Water and Environment Systems
Volume 14, Issue 1, March 2026, 1130643
DOI: https://doi.org/10.13044/j.sdewes.d13.0643
Wafae Arfaoui1 , Mouad Karmoun2, Khaoula Azzakhnini3, Mohamed Laarbi Elhafyani4, Smail Zouggar3, Hassan Zahboune3, Taoufik Ouchbel3, Adrian Alarcon Becerra5, Nikola Matak6
1 Université Mohammed premier,, Oujda, Morocco
2 Higher School of Technology of Oujda, Oujda, Morocco
3 Mohammed First University, Oujda, Morocco
4 UMP, Oujda, Morocco
5 Mohammed First University, Zaragoza, Spain
6 Faculty of Mechanical Engineering and Naval Architecture, Universty of Zagreb, Croatia

Abstract

This study examines how renewable energy integration influences power flow in Morocco’s national transmission grid. A detailed high-voltage network model was developed in GridCal using open-source data, and hourly simulations were carried out for four generation scenarios: a fully conventional system, an 8 percent solar case, a 12 percent wind case, and a 20 percent mixed renewable configuration representative of 2022. Results indicate that renewable generation alters both the magnitude and variability of transmission flows. Wind integration increased southern-corridor transfers from about 55 to 83 megawatts, while solar effects remained localized near production zones. These findings show that electrical connectivity and dispatch interactions, rather than geographic proximity, determine which corridors are most affected. The study provides a high-resolution framework for identifying transmission bottlenecks and supports Morocco’s energy-transition planning by linking renewable scenarios with grid-reinforcement priorities.

Keywords: Power grid, Renewable energy, Power flow, Electrical simulation, Solar generation, Wind generation, Grid stability

Creative Commons License
Views (in 2026): 658 | Downloads (in 2026): 207
Total views: 972 | Total downloads: 327
Introduction

Morocco has embarked on an ambitious energy transition to reduce fossil fuel dependence and raise the share of renewables in its power mix [1], [2]. Blessed with abundant solar and wind resources, the country targets roughly 52% of electricity generation from renewables by 2030 (up from ≈42% in 2020) [1], [2]. However, such high penetration of variable renewables poses significant technical challenges. The inherent variability and intermittency of solar and wind generation can induce large, rapid swings in supply that must be balanced against demand. As Che et al. note, reliance on weather-dependent sources “renders the task difficult for grid operators to ensure reliability, network stability, and power supply/demand balance” [3]. In other words, the natural intermittency of wind and solar “complicates grid stability” and can cause large voltage and frequency deviations if not managed properly [3]. To accommodate these fluctuations, utilities worldwide are deploying new flexibility measures (energy storage, demand response, grid interconnections, Power-to-X, etc.) [3]. Moreover, experts emphasize that integrating high shares of renewable generation fundamentally requires grid flexibility enhancements through advanced planning and control systems [3]. For instance, Taseska-Gjorgievska et al. [4] demonstrated that coupling long-term energy planning tools with transmission power-flow models is essential to accurately capture the operational constraints of high renewable penetration, reinforcing the need for detailed transmission-level analyses such as the one presented here.

A key concept for understanding these limits is hosting capacity (HC) which is the maximum new generation (e.g. PV or wind) that a grid can accommodate without violating thermal, voltage, protection, or stability limits [5]. Excessive distributed generation (DG) penetration beyond HC can produce over/under voltages, overload lines and transformers, increase losses, and even compromise protection schemes [6], [7]. For example, in an Albanian case study of solar PV in radial feeders, 100% PV penetration led to reverse power flow that “overloads the distribution transformers” and raises line temperatures, endangering equipment life [8]. Similarly, Mohsen et al. review that “excessive penetration” of DG causes various operational violations when a system exceeds its HC limit [7]. Notably, transformer HC can be substantially increased via dynamic rating: studies show that allowing higher real-time transformer loading (for example up to 35% above nameplate for PV hosting) can boost local HC without hardware changes [8]. These findings highlight that careful network management and controls are essential to raise the grid’s renewable capacity. Meanwhile transmission-level hosting capacity is inherently dynamic: available capacity depends on system-wide conditions and changes as generators retire or come online. In fact, industry experts note that transmission-hosting capacity cannot be captured by a static map; it varies with topology, contingency conditions, and hourly demand patterns [5]. This issue is compounded in developing countries, where detailed grid models and time-series data are often scarce. For example, Bollen and Rönnberg (2017) emphasize that accurate hosting capacity assessment requires high-resolution load and generation models, a requirement difficult to meet when empirical demand data are limited [9]. Hence, hosting-capacity analysis in data-scarce settings must carefully account for uncertainties and model limitations. Recent methodological work by Parrado-Hernando et al. [10] highlights that hourly variability of renewable energy must be explicitly modeled in order to assess integration impacts, further justifying the hourly-resolution approach used in this study.

Most recent studies of hosting capacity have focused on low-voltage or distribution networks; explicit transmission-level analyses in emerging regions remain few. Where investigated, authors generally use power-flow or optimization models on simplified systems. For instance, Essaid et al. (2025) [11] conducted load-flow simulations on a simplified Moroccan 5-bus network under four generation scenarios (no RES, all-solar, all-wind, and combined) to examine voltages and losses. They found that higher solar penetration tended to depress voltages at most buses, highlighting the need to monitor stability under high PV share. This study, though simplified, illustrates typical methods: Newton–Raphson AC power-flow analysis is used to obtain bus voltages and line flows for various renewable penetrations [11].

Boulakhbar et al. modelled Morocco’s 2030 supply mix and underscored the country’s challenge in meeting a 52% renewable target [1]. El Hafdaoui et al. comprehensively review Morocco’s energy strategy and identify that inefficiency in storage and distribution (resulting in only ~ 38 TWh available to end-users from ~ 43 TWh produced in 2022) underline the need for modernizing grid infrastructure and enhancing advanced planning. They argue these are essential not only to reduce losses and enhance grid stability amid growing renewable penetration, but also to meet ambitious decarbonization goals [2]. However, detailed studies of the Moroccan transmission network accurate models and power-flow analysis-remain scarce. Some Moroccan case studies have used energy system optimization or GIS tools to locate new hydro or solar plants, but they typically do not simulate network constraints explicitly. At the distribution level, international analyses Hida et al. show that PV siting and sizing significantly affect feeder voltages and losses, and that spreading PV evenly along feeders can raise hosting limits [8]. Yet analogous distribution grid HC analyses are not readily available for Morocco.

Naciri et al. (2023) [12] developed a deterministic hosting capacity model for underground radial feeders in Morocco’s medium-voltage distribution network, analyzing overvoltage, reverse power flow, and feeder overloading under different DG scenarios. By contrast, this study examines transmission-level lines across the whole year with realistic renewable scenarios to fill the gap left by distribution-focused analyses. Although, El Fahssi et al. (2023) [13] assessed Morocco’s grid reliability under various wind integration levels using Monte Carlo simulations, showing measurable changes in reliability indices. Meanwhile, Kirli et al. (2021) [14] developed a continental scale open-source network model for Africa using PyPSA to explore transmission-level impacts of high renewable shares. These studies inform related work, but few have conducted hourly transmission power-flow analysis on selected lines as this study does.

Comparable transmission-level studies in other developing regions confirm that renewable hosting capacity is a pressing concern, but they also reveal important methodological gaps. In Nigeria, Adetokun and Muriithi [15] found that large-scale wind integration strained weak 330 kV corridors, with voltage stability setting the practical hosting limit. Similarly, Abayateye and Zimmerle [16] showed that combining storage with thermal reserves improved frequency stability in the West African interconnected grid. While these studies demonstrate the importance of transmission-level assessments in emerging systems, they are generally limited to static snapshots, contingency analyses, or simplified network representations. In contrast, the present work models Morocco’s full transmission network with hourly demand and renewable generation profiles across multiple penetration scenarios, providing a unique temporal perspective on flow variability and highlighting the operational challenges of renewable integration in a data-scarce setting.

These gaps highlight several challenges: obtaining accurate grid data and load profiles, modelling intermittent generation in fine time steps, and identifying the specific transmission bottlenecks under realistic variations. In particular, published studies rarely couple real operational demand and generation time series with power-flow analysis for African or MENA high-voltage systems. Thus, a high-resolution analysis of hourly line flows under diverse renewable scenarios in Morocco’s grid has not been reported in the literature.

To address this gap, the present study uses a detailed model of Morocco’s high voltage transmission network with operating conditions representative of 2022. Demand and renewable generation inputs were derived from open-source datasets and platforms (e.g., OpenStreetMap, Renewables.ninja) combined with national statistics, as described in the data section of this article. Simulations were carried out in the GridCal environment, applying hourly load and renewable generation profiles. Four scenarios were modelled: a purely conventional (100% conventional production plants only), an 8% solar scenario, a 12% wind scenario, and a 20% mixed renewables scenario aligned with Morocco’s 2022 case. In each case, the active power flow on two selected transmission lines was computed for every hour of the year. This approach enables the visualization of hourly flow variations under different renewable integration patterns, providing insights into the temporal and spatial impacts of solar and wind integration on the Moroccan transmission grid.

The concept of transmission-level hosting capacity has evolved beyond static limits to multidimensional frameworks that incorporate network congestion, flexibility markets, and dynamic dispatch behaviour. Recent studies demonstrate that optimizing both energy and flexibility products can significantly increase renewable hosting capacity in large transmission systems [17]. In parallel, a comprehensive 20-year review of HC methods emphasizes the shift toward probabilistic, time-series, and feasible-region formulations that capture temporal variability and uncertainty [18]. Together, these advances set a new methodological standard for analysing large-scale renewable integration at the transmission level.

The challenge of conducting detailed power-flow analysis under limited data availability is increasingly being addressed through open-source and synthetic network modelling. For instance, Scientific Data reports an open-access high-voltage grid model derived entirely from public sources, showcasing the reproducibility and transparency possible in such contexts [19]. These developments align with the objectives of studies focusing on African and emerging systems, where official network data are scarce but open-data methodologies provide a practical pathway to credible national-level analysis.

System-side flexibility measures including energy storage, curtailment control, and export constraints have been shown to raise renewable hosting capacity and reduce transmission congestion in highly variable networks. A hierarchical optimization framework demonstrates that combining renewable and electric-vehicle integration with storage yields substantial improvements in network HC [20]. Complementary analyses highlight how coordinated flexibility markets enhance grid utilization and hosting potential [17], [21].

Beyond individual case studies, recent reviews of European grid-development frameworks emphasize unified modelling approaches that couple open data, optimization, and planning for future transmission expansion [21]. Similarly, a large-scale synthesis of hosting-capacity enhancement techniques catalogues deterministic, stochastic, and control-aware methods, recommending integrated approaches that link renewable variability with grid stability metrics [22].

Building on these academic developments, this study introduces a comprehensive and high-resolution analysis of Morocco’s national transmission network assembled entirely from open-source data.

The novelty of this work lies primarily in two aspects.

  • It develops a national-scale transmission-system model for Morocco constructed exclusively from open data under conditions of limited data availability in an African context. The model incorporates a high level of spatial and technical detail, capturing realistic voltage levels, line parameters, and substation configurations rather than a simplified or aggregated representation. This framework demonstrates how detailed, country-level grid modelling can be achieved using publicly available sources.

  • It applies this detailed model to perform year-long hourly power-flow simulations across two geographically distinct transmission corridors under multiple renewable-integration scenarios, enabling a comparative evaluation of system performance at the national scale. While the power-flow methodology itself is established, its application to a finely resolved Moroccan network and its use for corridor-level comparison provide new insights into renewable-integration challenges and opportunities in data-scarce power systems.

  • Collectively, these contributions bridge an important knowledge gap in the regional literature and provide a reproducible methodological framework for assessing renewable-energy hosting capacity in developing-country grids.

    Methods

    The first step of this study was the development of a detailed model of the Moroccan high voltage transmission network using the open source GridCal environment. GridCal was chosen because it combines an intuitive graphical interface with robust power-flow solvers, supports large-scale network representations, and facilitates the integration of hourly time-series data for loads and renewable generation, making it well suited for hosting capacity and flow variability studies in data-scarce contexts.

    Transmission Network Model

    Constructing the model required assembling technical and geographical information on all major system components. Substations were characterized by their nominal voltage levels and geospatial coordinates. Generation units were specified by their installed capacity and explicitly connected to their corresponding substations. Transformers were represented through their sending and receiving busbars and reactance values. Transmission lines were described by connectivity between busbars, physical length, and electrical parameters, namely resistance (R) and reactance (X). Regional loads were defined by active (P) and reactive (Q) demand values, together with their nodal connection and temporal consumption profiles. Finally, renewable energy facilities were represented by hourly production profiles for solar and wind sites, mapped to their respective grid nodes. This structured dataset enabled the implementation of a coherent transmission network model suitable for time-series power-flow simulations.

    Given the strategic and confidential nature of official electrical grid data in Morocco, direct access to internal datasets from the national utility (ONEE) was not possible. To overcome this limitation, open-source platforms, primarily OpenStreetMap and the query interface Overpass Turbo, were used to reconstruct the transmission infrastructure [23], [24]. The raw data extracted included the geographical coordinates, voltage levels, and functional classifications of substations and transmission lines. This information was converted and structured into spreadsheets using a customized Python script. The script parsed GeoJSON files to extract bus locations, calculate transmission line lengths, and classify electrical elements by type.

    For generation units attributes such as nominal voltage, generation capacity, and geolocation were extracted and assigned to corresponding bus nodes. A similar procedure was followed for transformers, where attributes were assigned to their corresponding bus nodes. For transmission lines, physical parameters (resistance R, reactance X) were computed based on standard conductor characteristics.

    The resistance was calculated as:

    R=ρ/A

    where ρ is the conductor resistivity (Ω·m) and A is cross-sectional area (m2) [25].

    The series reactance was given by:

    X=2πfL

    Where f is the system frequency (Hz) and L is the line inductance (H/m) [26], defined as:

    L= 2.10 7 ln D r

    where D is spacing between conductors (m) and r is conductor radius (m) [27]. For transformers, equivalent reactance values were calculated in per-unit format, referenced to the transformer's base MVA rating [28].

    Applying the above formulations and data extraction process enabled the construction of a comprehensive database of the Moroccan transmission system. This database includes:

    • Electrical substations: Nominal voltages and geographical coordinates.

    • Generation units: installed capacities and their connection points to substations.

    • Transformers: sending and receiving busbars and corresponding reactance values.

    • Transmission lines: sending and receiving busbars, electrical parameters (resistance and reactance), and physical length.

    • Loads: active and reactive power values with their connection to specific busbars.

    • Hourly profiles: demand variation at major substations and renewable generation time series.

    The Moroccan power grid is based on an infrastructure comprising 55 generation units, distributed as follows:

    • 11 thermal power plants,

    • 20 hydroelectric power plants,

    • 10 wind farms,

    • 11 solar farms,

    • 3 gas-fired generation units.

    The high and extra-high voltage (HV/EHV) transmission network consists of:

    • 370 electrical distribution substations,

    • 604 transmission lines, with a total length of 16,161 km, distributed as follows:

    • 9,002 km for 52 kV – 131 kV lines,

    • 102 km for 132 kV – 219 kV lines,

    • 5,968 km for 220 kV – 329 kV lines,

    • 1,089 km for 330 kV – 549 kV lines.

  • Approximately 77 transformers, ensuring interconnection between different voltage levels within the grid [29].

  • Demand Data and Load Modelling

    Since regional electrical load data are also not publicly available at high resolution, an extrapolation approach was employed using population density and known regional consumption benchmarks (primarily from the Oriental region). The following proportional estimation was applied:

    P region = Pop region Pop east × P east

    Where Pregion is the estimated power in region Popregion is the population of region Peast, and Popeast are the power and population of the Oriental region, respectively. This method is based on the assumption that energy consumption is proportional to population commonly used approximation in energy planning studies [30].

    Table 1 summarizes the regional population of Morocco [31] and corresponding peak demand estimates. The aggregated peak demand (≈ 6.9 GW) is consistent with Morocco’s official 2022 peak demand of 7.2 GW [32] , validating the extrapolation method.

    Regional population (2022) and estimated peak electrical demand based on population-scaling method

    Morocco’s regions

    Population in 2022

    Estimated Demand [MW]

    Oriental

    2,505,730

    470.77

    Tangier–Tetouan–Al Hoceima

    3,900,359

    732.79

    Fes–Meknes

    4,460,667

    838.06

    Rabat–Sale–Kenitra

    4,962,561

    932.36

    Beni Mellal–Khenifra

    2,642,554

    496.48

    Casablanca–Settat

    7,596,040

    1427.13

    Marrakech–Safi

    4,857,033

    912.53

    Draa–Tafilalet

    1,712,526

    321.75

    Souss–Massa

    2,977,128

    559.34

    Guelmim–Oued Noun

    450,486

    84.64

    Laayoune–Sakia El Hamra

    412,005

    77.41

    Dakhla–Oued Ed-Dahab

    193,127

    36.28

    Total

    36,670,216

    6,889.54

    To generate representative hourly demand profiles, the regional peak loads were scaled using the normalized temporal load variation published by NREL in collaboration with ONEE for Morocco (2018) [33]. This dataset provides typical hourly demand shapes across months, which allows extrapolating realistic year-round consumption patterns from regional peak estimates.

    To illustrate the demand input data, Figure 1 represents the hourly load profile of the Oriental region, obtained from the NREL–ONEE dataset [33]. The full-year curve (Figure 1a) captures the seasonal and annual variation, while the zoomed-in 100-hour window (Figure 1b) highlights the characteristic daily peaks and troughs. The normalized profile was used as the benchmark to scale regional peak loads (Table 1), thereby generating consistent hourly demand curves for all Moroccan regions. The resulting national load time series retains both realistic daily/seasonal variability and a plausible peak magnitude consistent with reported national statistics.

    Hourly demand profile of the Oriental region of Morocco in 20222, derived from the NREL–ONEE dataset [33]: (a) full-year hourly variation; (b) zoomed-in detail for a representative 100-hour period

    Renewable Energy Profiles

    Wind generation was simulated using Renewables.ninja, which employs reanalysis climate datasets and physical turbine models to produce realistic hourly wind power output based on site-specific coordinates [34]. Renewables.ninja has been validated against measured production in several countries, confirming its reliability for high-resolution time-series modelling of wind power [35]. For Morocco, the model was applied to all major wind farm locations, and the outputs were aggregated to obtain the national wind production profile.

    Figure 2 shows the evolution of energy production from all Moroccan wind farms in 2022. This profile is based on heuristic data, simulating wind variability over an entire year. A more detailed analysis of production over a 100-hour period is also included to evaluate short-term fluctuations.

    Total energy produced by all wind farms in Morocco in 2022 simulated with Renewables.ninja [34]: (a) hourly production over the full year; (b) zoomed-in variation over a representative 100-hour period

    Solar photovoltaic production was estimated using the Photovoltaic Geographical Information System (PVGIS), which provides hourly irradiance and conversion data for site-specific coordinates across Morocco [36]. PVGIS, developed and maintained by the European Commission’s Joint Research Centre, is widely applied for PV resource and yield assessment in Europe, Africa, and MENA [37]. In this study, PVGIS was used to generate hourly production profiles for the main solar sites in Morocco, which were then aggregated to obtain a national-scale solar production curve.

    Figure 3 illustrates the solar energy production across all solar plants in the country. This profile highlights the daily and seasonal variations characteristic of this energy source. Similarly, a detailed 100-hour analysis is included to study the stability of solar injection into the grid.

    Total energy produced by all solar farms in Morocco in 2022 simulated with PVGIS [36]: (a) hourly production over the full year; (b) zoomed-in variation over a representative 100-hour period.

    Scenarios Definition

    Four simulation scenarios were defined to evaluate the impact of the gradual integration of renewable energies into the Moroccan power grid. These scenarios are described as follows:

    • 100% Conventional Scenario;

    • Scenario with 8% Solar Energy;

    • Scenario with 12% Wind Energy;

    • Mixed Scenario: 20% of RES (the case of Morocco in 2022);

    • 100% Conventional Scenario: In this first case, it is assumed that all electrical production

    • comes solely from conventional sources (thermal power plants, hydroelectric plants, etc.),

    • with no contribution from intermittent renewable energies.

    Scenario with 8% Solar Energy: This scenario modifies the energy mix by replacing 8% of conventional production with solar energy. It analyses the impact of injecting this intermittent production into the grid.

    Scenario with 12% Wind Energy: Here, 12% of conventional production is replaced by wind energy, enabling an assessment of the impact of wind power variations on stability and power flow management.

    Mixed Scenario: This final scenario reflects Morocco’s actual situation in 2022, where 8% of production comes from solar and 12% from wind. This case allows the current performance of the grid to be measured in response to this combination of renewable energies.

    Results

    The processed datasets were integrated into GridCal, an open-source power system modelling and simulation tool [38]. GridCal supports steady-state power flow calculations, contingency analysis, and hosting capacity studies, making it suitable for evaluating renewable integration impacts on large transmission networks. The regional demand profiles, generation units, and network parameters described in the previous sections were assigned to the corresponding substations and transmission elements within the Moroccan grid model.

    As a baseline, the system was first simulated under a 100% conventional scenario, i.e. considering only existing thermal and hydroelectric plants without renewable penetration. This case provides a reference point for quantifying the impacts of subsequent renewable integration scenarios on network utilization and stability.

    Figure 4 illustrates the complete structure of the Moroccan transmission network as implemented in GridCal. This modelling enables the observation of the interconnections configuration between the various electrical infrastructures.

    The Moroccan transmission network modelled in the GridCal software

    Figure 5 provides a close-up view of a specific section of the network, highlighting the complexity of the grid and substations. This detailed approach allows us to refine power flow analyses and detect potential constraints.

    Zoomed-in detail of a section of the Moroccan transmission network modelled in the GridCal software

    Power Flow Simulation

    For power flow visualization, two representative transmission lines were selected in different regions of Morocco. The first is located in the south near Ouarzazate, a region hosting large-scale solar power plants, while the second is situated in the north, close to major wind farm installations. This selection enables a differentiated assessment of how solar and wind integration affect transmission flows in distinct parts of the grid.

    Figure 6 represents the power flow of the transmission line located in northern Morocco. Figure 6a provides the variation of this line’s power flow throughout the year and the Figure 6b over 14 days in January.

    The power flow of a transmission line located in northern Morocco: (a) throughout the year; (b) over 14 days in January

    In this 100% conventional scenario, the power flow remains relatively stable thanks to thermal power plants, which provide a certain inertia to the grid. This means they help maintain balance by naturally absorbing demand variations. However, with the integration of renewable energies such as solar and wind, this stability could be affected. Since these sources are more variable; the grid will need to adapt further to prevent excessive fluctuations, notably by using energy storage or advanced regulation systems.

    Figure 7 shows the evolution of the power flow of the line located in the southern Morocco over the course of the year. The values are negative, indicating a power flow in the opposite direction to the adopted convention. The power varies between approximately −35 MW and −55 MW, suggesting a stable energy injection with some seasonal fluctuations.

    The power flow of a transmission line in Ouarzazate, Morocco: (a) throughout the year; (b) over 16 days in January

    In the 100% conventional scenario, active-power flow on the southern line varied between –55 MW and –37 MW (Figure 7a). Over a representative January period (Figure 7b), values ranged from –55 MW to –41 MW, showing moderate daily oscillations of about 18 MW.

    • Scenario with 8% Solar Energy: The integration of solar energy increases the variability of power flow, which can pose challenges for grid stability. However, the line transmits more power compared to the 100% conventional scenario, reaching up to –87 MW at peak hours (Figure 8a) a 32 MW rise relative to the baseline maximum. The flow range expanded from 18 MW to 87 MW. This variability is mainly due to the day-night cycle and weather conditions, which directly impact solar production.

    • Scenario with 12% Wind Energy: In this case, flow values ranged between –72.7 MW and –70.9 MW (Figure 8b). Fluctuations are less pronounced since this line is far from the installed wind farms, making their influence minimal. Although the direct impact of wind energy on this line is limited, it is important to note that wind power can sometimes be more stable than solar, especially during prolonged periods of steady wind. However, sudden weather changes can cause rapid variations, requiring better coordination with other energy sources or compensation mechanisms within the grid [39], [40].

    • Mixed Scenario: The mixed 8 % solar +12 % wind scenario produced maximum flows around –95 MW (Fig. 8c), a 40 MW rise from the conventional case. The annual variability decreased slightly relative to the solar-only case, confirming a partial smoothing effect between solar and wind contributions.The profile in this scenario is quite similar to the 8% solar energy scenario, indicating that power flow is mainly influenced by energy sources located near the line.

    Power flow of a transmission line in Ouarzazate, Morocco: (a) Scenario with 8% Solar Energy; (b) Scenario with 12% Wind Energy; (c) Mixed Scenario

    Power flow of a transmission line in Ouarzazate, Morocco, over several days in January: (a) Scenario with 8% Solar Energy; (b) Scenario with 12% Wind Energy; (c) Mixed Scenario

    For the 100 % conventional case (Figure 6a), the northern line carried between 15 MW and 54 MW, with daily variations of roughly 25 MW in January (Figure 6b). These values indicate lower baseline utilization compared with the southern corridor.

    In contrast, the 8% Solar Energy scenario (Figure 10a) yielded flows between 14 MW and 50 MW, practically unchanged from the baseline, confirming that solar generation in southern regions exerts little influence on northern transmission flows, due to the location of the line relative to the installed energy sources.

    Power flow of a transmission line in northern Morocco: (a) Scenario with 8% Solar Energy; (b) Scenario with 12% Wind Energy; (c) Mixed Scenario

    Power flow of a transmission line in northern Morocco over several days in January: (a) Scenario with 8% Solar Energy; (b) Scenario with 12% Wind Energy; (c) Mixed Scenario

    When moving to the 12% Wind Energy scenario (Figure 10b), the line’s flow magnitude increased markedly to approximately 190 MW, compared to 54 MW in the baseline, reflecting the strong influence of northern wind farms.

    Finally, under the mixed Scenario peaks reached nearly 200 MW (Figure 10c), similar to the wind-only scenario. This confirms that wind generation dominates power-flow dynamics in the northern region, while solar injection has little compensating effect here.

    Overall, unlike the previous (southern) line, this northern one is more impacted by wind integration due to its proximity to installed wind farms. To synthesize these findings, Table 2 provides a consolidated view of the annual power-flow statistics for the northern and southern lines under all simulated scenarios. The numerical comparison reveals that solar integration primarily amplifies flow variability in southern corridors, whereas wind penetration exerts a stronger influence on northern transmission paths.

    Summary of Active-Power Flow Results for Northern and Southern Transmission Lines under Renewable Integration Scenarios

    Scenario

    Minimum Flow [MW]

    Maximum Flow [MW]

    Range [MW]

    Absolute Peak [MW]

    Δ Peak vs Baseline [MW]

    Southern (Ouarzazate)

    100% Conventional

    –55

    –37

    18

    55

    8% Solar PV

    –87

    0

    87

    87

    +32

    12% Wind

    –72.7

    –70.9

    1.8

    72.7

    +17.7

    Mixed RES

    –95

    0

    95

    95

    +40

    Northern (Tétouan)

    100% Conventional

    15

    54

    39

    54

    8% Solar PV

    14

    50

    36

    50

    –4

    12% Wind

    25

    190

    165

    190

    +136

    Mixed RES

    25

    200

    175

    200

    +146

    Note. Positive values indicate north-to-south power transfer; negative values indicate the opposite direction. All simulations were performed over a full annual horizon of 8760 hours.

    The analysis of these scenarios shows that the integration of renewable energies has a significant impact on the power flow of the grid. While solar energy increases the variability of the flow, wind energy can, in some cases, offer more stability, although it depends on local weather conditions. The mixed scenario seems to be an interesting alternative, combining the benefits of both sources. However, to ensure the optimal functioning of the grid, adaptation measures will be necessary, such as integrating storage solutions, improving grid flexibility, and optimising transmission infrastructure.

    Discussion

    The analysis of the four simulated scenarios reveals that the integration of renewable energy sources significantly modifies the temporal dynamics of power flow within Morocco’s transmission grid. While both solar and wind energy contribute to decarbonization and resource diversification, their distinct production patterns produce different operational impacts on transmission corridors. Solar generation introduces pronounced diurnal variability, with strong daytime peaks followed by sharp evening drops, whereas wind generation exhibits greater variability on multi-hour and multi-day timescales. These differences translate into distinct line-loading behaviours that must be accounted for in operational planning.

    A key finding of this study is that geographic proximity alone does not determine which transmission corridors are stressed by renewable integration. Although the 12% wind scenario concentrates generation mainly in the north, the southern (Ouarzazate) corridor also experienced noticeable increases in power flow. Specifically, the southern line’s active power rose from around −55 MW in the baseline case to nearly −83 MW under the 12% wind scenario, while the northern line’s flow changed only modestly from approximately 47 MW to 52 MW in the 8% solar case. This difference demonstrates that lines distant from generation sites can still undergo large flow variations when dispatch conditions and network impedance paths favour them.

    This behaviour arises from the electrical topology and dispatch interactions within the grid: when wind generation surpluses occur, conventional plants especially in the south are displaced, causing bulk northward transfers through the southern line. Conversely, in the 8% solar scenario, the effects remained largely confined to the solar-rich zones in the south, with limited influence on the northern corridor. This contrast highlights that power flow redistribution depends on the system’s electrical configuration and impedance paths, not simply on the geographical location of renewable sites.

    The practical implication is clear: network reinforcement and flexibility planning must be based on electrical distance and power-flow sensitivity rather than geographic proximity. Corridors far from renewable clusters can still experience significant load changes when surplus generation is transmitted toward major demand centres. For Morocco, this means that transmission upgrades, dispatch strategies, and eventual storage siting should rely on quantitative sensitivity metrics such as Power Transfer Distribution Factors (PTDFs) to identify which lines are most affected by renewable injections under realistic system conditions.

    The results obtained here align with and expand upon earlier Moroccan studies. El Fahssi et al. (2023) [13] reported that wind integration significantly modifies system reliability indicators, with stress appearing even on lines geographically distant from wind farms ‒ consistent with the present finding that the southern corridor experiences increased loading under northern wind generation. Similarly, Naciri et al. (2023) [12] quantified hosting capacity at the distribution level, emphasizing that voltage and thermal constraints emerge well before nominal equipment ratings are reached. This study complements previous findings by providing a transmission-level perspective: rather than probabilistic or feeder-level analysis, hourly variations of bulk-power transfers are captured, and the large-scale corridors most sensitive to renewable injections are identified. Essaid et al. [11] found that solar injections in Morocco’s simplified 5-bus model produced localized voltage depressions and flow variability near PV nodes but limited influence on remote lines. Compared with those earlier works, the present study extends the analysis by using a detailed national transmission model and hourly simulation over an entire year, offering a higher-resolution view of flow dynamics under realistic renewable scenarios.

    Overall, the comparative analysis suggests that solar energy tends to increase short-term variability of power flow, while wind energy depending on its temporal correlation with demand can either stabilize or further accentuate daily fluctuations. The mixed 20% RES case exhibits a smoother aggregate pattern, indicating that a balanced combination of solar and wind reduces the amplitude of flow oscillations across major transmission corridors. These results support ongoing efforts to diversify Morocco’s renewable mix, while emphasizing the importance of adaptive grid management and regional coordination to accommodate future renewable expansion.

    Although energy-storage systems were not explicitly modelled in this study, their potential influence on hosting capacity is significant. Storage can mitigate hourly imbalances between renewable generation and demand by shifting surplus energy and reducing congestion on heavily loaded corridors. In practice, technologies such as pumped-hydro storage or grid-scale batteries could absorb excess solar output during midday hours and discharge in evening peaks, effectively flattening line loadings and improving voltage stability. Integrating such flexibility resources into future simulations would therefore refine the assessment of Morocco’s renewable-energy hosting capacity.

    Conclusion

    This study assessed the impact of renewable energy integration on Morocco’s transmission network through detailed hourly power flow simulations under four generation scenarios: a 100% conventional baseline, an 8% solar case, a 12% wind case, and a mixed 20% RES configuration representative of 2022. The results show that renewable penetration substantially alters the temporal and spatial distribution of power flows across the grid. Solar generation amplifies short-term variability, while wind power influences multi-day transfer patterns; their combination produces a smoother overall flow profile.

    Quantitatively, the southern corridor’s flow magnitude increased from about −55 MW in the baseline to nearly −83 MW in the 12% wind scenario, whereas the northern line changed only modestly from 47 MW to 52 MW in the 8% solar case. The results demonstrate that it is the network’s electrical connectivity and dispatch interactions, rather than simple geographic proximity, that determine which transmission corridors are most affected by renewable-energy injections.

    Although energy-storage systems were not explicitly modelled in this study, their potential influence on hosting capacity is considerable. Storage can mitigate hourly imbalances between renewable generation and demand by shifting surplus energy and reducing congestion on heavily loaded corridors. In practical terms, technologies such as pumped-hydro or grid-scale batteries could absorb excess solar output during midday hours and discharge in evening peaks, effectively flattening line loadings and enhancing grid flexibility. Including such flexibility resources in future analyses would therefore refine the assessment of Morocco’s renewable energy hosting capacity.

    The findings underline the importance of incorporating electrical sensitivity metrics such as Power Transfer Distribution Factors into Morocco’s transmission-planning and operational studies. They also suggest that combining solar and wind resources can moderate flow variability, supporting system reliability. Future work will extend the analysis to include voltage-stability and N-1 contingency analyses, together with explicit modelling of storage integration to provide a more comprehensive assessment of Morocco’s renewable hosting capacity.

    These results provide practical value for Moroccan grid planners and energy policymakers. Anticipating and managing the local and systemic impacts of renewables is essential for ensuring reliable power delivery during the country’s energy transition.

    In addition to these technical findings, the study demonstrates a practical approach for reconstructing a national-level transmission network using publicly available data. The combination of OpenStreetMap and Overpass Turbo enabled the extraction and spatial mapping of line routes and substations, while standard electrical parameters were assigned according to voltage level. This open-data methodology provides a transparent and reproducible foundation for power-system studies in regions where detailed grid information is not publicly accessible.

    Future work will focus on analysing branch loading across different lines and renewable integration scenarios. By examining how transmission elements approach their loading limits, it will be possible to identify optimal locations and capacity levels for renewable energy deployment. This approach will help determine where and how much renewable generation can be integrated without compromising the reliability or stability of the Moroccan transmission network. In addition, future analyses will incorporate voltage-profile and contingency studies, together with the explicit modelling of storage integration, to evaluate how flexibility resources can enhance the hosting capacity of the Moroccan grid.

    Acknowledgment
    Acknowledgments

    The authors express their gratitude for the support received from the CNRST under the « PhD-Associate Scholarship-Pass » Program.

    The paper is prepared within the framework of the EMERGE project, Call for proposals: HORIZON-CL5-2022-D3-02. Project number: 101118278. Type of action: Research and innovation actions HORIZON, 2023.

    REFERENCES
    1. Boulakhbar M., Lebrouhi B., Kousksou T., Smouh S., Jamil A., Maaroufi M., Zazi M., , Towards a Large-Scale Integration of Renewable Energies in Morocco, Journal of Energy Storage, Vol. 32 , :1018062020, https://doi.org/10.1016/j.est.2020.101806
    2. El Hafdaoui H., Khallaayoun A., Al-Majeed S., , Renewable Energies in Morocco: A Comprehensive Review and Analysis of Current Status, Policy Framework, and Prospective Potential, Energy Conversion and Management: X, Vol. 26 , :1009672025, https://doi.org/10.1016/j.ecmx.2025.100967
    3. Ejuh Che E., Roland Abeng K., Iweh C., Tsekouras G., Fopah-Lele A., , The Impact of Integrating Variable Renewable Energy Sources into Grid-Connected Power Systems: Challenges, Mitigation Strategies, and Prospects, Energies, Vol. 18 (3), :6892025, https://doi.org/10.3390/en18030689
    4. Taseska-Gjorgievska V., Todorovski M., Markovska N., Dedinec A., An integrated approach for analysis of higher penetration of variable renewable energy: coupling of the long-term energy planning tools and power transmission network models, Journal of Sustainable Development of Energy, Water and Environment Systems, Vol. 7 (4), :615-6302019, https://doi.org/10.13044/j.sdewes.d7.0264
    5. , , https://dnr.maryland.gov/pprp/Pages/default.aspx, ‘Maryland Department of Natural Resources, Hosting capacity FAQ,, [Accessed: Sep. 23, 2025]
    6. Hamdan I., Alfouly A., Ismeil M., A literature review on hosting capacity methodologies and inverter control technologies for photovoltaic system, 2023 IEEE Conference on Power Electronics and Renewable Energy (CPERE), 2023
    7. Herding L., Carvalho L., Cossent R., Rivier M., A security-aware dynamic hosting capacity approach to enhance the integration of renewable generation in distribution networks, International Journal of Electrical Power & Energy Systems, Vol. 161 , :1102102024, https://doi.org/10.1016/j.ijepes.2024.110210, Art. no.
    8. Hida A., Karapici O., Bualoti R., Gashi D., , Impact of Photovoltaic Penetration on the Distribution System Operation: Case Study Albania, Journal of Sustainable Development of Energy, Water and Environment Systems, Vol. 13 (2), :11305482025, https://doi.org/10.13044/j.sdewes.d13.0548
    9. Bollen M., Rönnberg S., , Hosting Capacity of the Power Grid for Renewable Electricity Production and New Large Consumption Equipment, Energies, Vol. 10 (9), :13252017, https://doi.org/10.3390/en10091325
    10. Parrado-Hernando G., Frechoso-Escudero F., Miguel González L., , Method to Model the Hourly Variability of Renewable Energy Sources in Integrated Assessment Models, Journal of Sustainable Development of Energy, Water and Environment Systems, Vol. 12 (1), :11104812024, https://doi.org/10.13044/j.sdewes.d11.0481
    11. Essaid S., Lazrak L., Ghazaoui M., , Renewable Energy Impact Integration in Moroccan Grid-Load Flow Analysis, International Journal of Electrical and Computer Engineering (IJECE), Vol. 15 (4), :3632-36482025, https://doi.org/10.11591/ijece.v15i4.pp3632-3648
    12. Naciri S., Moufid I., El Moussaoui H., Lamhamdi T., El Markhi H., , A Deterministic Method of Distributed Generation Hosting Capacity Calculation: Case Study of Underground Distribution Grid in Morocco, International Journal of Electrical and Computer Engineering (IJECE), Vol. 13 (1), :144-1582023, https://doi.org/10.11591/ijece.v13i1.pp144-158
    13. El Fahssi M., Ouchbel T., Zouggar S., Larbi Elhafyani M., Oukili M., Maaouane M., Chennaif M., Lecture Notes in Electrical Engineering, Proceedings of the 3rd International Conference on Electronic Engineering and Renewable Energy Systems (ICEERE 2023), 2023
    14. Kirli D., Hampp J., van Greevenbroek K., Grant R., Mahmood M., Parzen M., Kiprakis A., , PyPSA Meets Africa: Developing an Open Source Electricity Network Model of the African Continent, arXiv preprint arXiv:2110.10628, 2021, https://doi.org/10.48550/arXiv.2110.10628
    15. Adetokun B., Muriithi C., Impact of integrating large-scale DFIG-based wind energy conversion system on the voltage stability of weak national grids: A case study of the Nigerian power grid, Energy Reports, Vol. 7 , :654-666(2021), https://doi.org/10.1016/j.egyr.2021.01.025
    16. Abayateye J., Zimmerle D., , Analysis of Grid Scale Storage Effectiveness for a West African Interconnected Transmission System, Energies, Vol. 18 (14), 2025, https://doi.org/10.3390/en18143741, Article 3741
    17. Mousavi M., Azarnia M., Zhong J., Rönnberg S., Maximization of Renewable Generation Hosting Capacity in Power Transmission Grids Considering Participation in Energy and Flexibility Markets: A Bilevel Optimization Model, Sustainable Energy, Grids and Networks, Vol. 41 , :1016332025, https://doi.org/10.1016/j.segan.2025.101633
    18. Tavares de Oliveira T., Bollen M., Etherden N., Bhattacharyya S., Bahramirad S., 20 Years of Hosting Capacity Studies, 2004–2024, IET Generation, Transmission & Distribution, Vol. 19 (1), 2025https://urn.kb.se/resolve?urn=urn:nbn:se:ltu:diva-113421
    19. Xiong B., Fioriti D., Neumann F., Riepin I., Brown T., Modelling the High-Voltage Grid Using Open Data for Europe and Beyond, Scientific Data, Vol. 12 (1), :2772025, https://doi.org/10.1038/s41597-025-04550-7
    20. Almutairi S., Alharbi A., Ali Z., Refaat M., Aleem S., A Hierarchical Optimization Approach to Maximize Hosting Capacity for Electric Vehicles and Renewable Energy Sources Through Demand Response and Transmission Expansion Planning, Scientific Reports, Vol. 14 (1), :157652024, https://doi.org/10.1038/s41598-024-66688-5
    21. Qu C., Bang R., European Grid Development Modeling and Analysis: Established Frameworks, Research Trends, and Future Opportunities, Discover Energy, Vol. 4 (1), :92024, https://doi.org/10.1007/s43937-024-00033-9
    22. Mousa H., Mahmoud K., Lehtonen M., A Comprehensive Review on Recent Developments of Hosting Capacity Estimation and Optimization for Active Distribution Networks, IEEE Access, Vol. 12 , :18545-185932024, https://doi.org/10.1109/ACCESS.2024.3359431
    23. , , https://www.openstreetmap.org/, [Accessed: Jul. 01, 2025]
    24. , , https://overpass-turbo.eu/, [Accessed: Jul. 01, 2025]
    25. , , 2016
    26. Ge Q., Li Z., Liu S., Xing J., Formulas Calculating the Reactance of Tubular Busbars and Their Derivation in Primary Electrical Connection Schemes, Scientific Reports, Vol. 13 (1), 2023, https://doi.org/10.1038/s41598-023-30408-2, Article 3223
    27. , AC Transmission Line Model Parameter Validation, Report to the Line Protection Subcommittee of the Power System Relay Committee, 2014
    28. Kundur P., ‘Power system stability’, Power system stability and control, Vol. 10 (1), :7-12007
    29. Oukili M., Zouggar S., Vallée F., Seddik M., Ouchbel T., Impact of Wind Power Integration and Load Evolution on the Moroccan Electrical Grid Reliability (in English, published via Francophone repository), Int. J. Electr. Eng. Transp., Vol. 6 (1), :1-82010https://orbi.umons.ac.be/handle/20.500.12907/16194, [Accessed: June. 30, 2025]
    30. Oukili M., Zouggar S., Seddik M., Vallée F., El Hafyani M., Ouchbel T., Evaluation of the Moroccan Power Grid Adequacy with Introduction of Concentrating Solar Power (CSP) Using Solar Tower and Parabolic Trough Mirrors Technology, Energy Procedia, Vol. 42 , :113-1222013, https://doi.org/10.1016/j.egypro.2013.11.011
    31. Projections of the Population of Regions and Provinces 2014–2030 (in French, Projections de la population des régions et des provinces 2014–2030) , 2017[Accessed: Oct. 02, 2025]
    32. 2023 Annual Activity Report (in French, Rapport Annuel d’Activité 2023) , 2023[Accessed: Oct. 01, 2025]
    33. Cox J., De Silva T., Jorgenson J., O‟Neill B.Load Forecasting for the Moroccan Electricity Sector, Technical Report, , 2021
    34. , , https://www.renewables.ninja/, [Accessed: Jul. 02, 2025]
    35. Pfenninger S., Staffell I., Long-term Patterns of European PV Output Using 30 Years of Validated Hourly Reanalysis and Satellite Data, Energy, Vol. 114 , :1251-12652016, https://doi.org/10.1016/j.energy.2016.08.060
    36. , , https://pvgis.com/fr/pvgis-5-3, [Accessed: Jul. 02, 2025]
    37. Huld T., Müller R., Gambardella A., A New Solar Radiation Database for Estimating PV Performance in Europe and Africa, Solar Energy, Vol. 86 (6), :1803-18152012, https://doi.org/10.1016/j.solener.2012.03.006
    38. Baghaz E., Louzazni M., Faize A., Proceedings of the First International Conference on Bio-Materials Science, Mechanical, and Electrical Engineering (ICBMSM2E’24), 2024
    39. Weber J., Rahimi R., Waechter M., Peinke J., Milan P., Wind Power Persistence Characterized by Superstatistics, Scientific Reports, Vol. 19 (1), :199712019, https://doi.org/10.1038/s41598-019-56286-1
    40. D‟Amico G., Petroni F., Vergine S., Ramp Rate Limitation of Wind Power: An Overview, Energies, Vol. 15 (16), 2022, https://doi.org/10.3390/en15165850, Article 5850

    DBG