Introduction

Background

The remarkably high population growth and weakening of surface water supply in Dar es Salaam City over the past two decades has come at a tremendous cost to the Dar es Salaam Quaternary coastal aquifer (DQCA). City’s water demand is about 424,000 m3/day (Mato and Mjwahuzi 2010). In Dar es Salaam City, where this study is based, almost all rivers are polluted and for over four decades the main surface water supply is from Ruvu River which flows about 65 km away from the city. However, for over two decades, especially since 1997, water level in Ruvu River is declining. Decrease of water level in Ruvu River is attributed to drought and disturbance of its catchments by human activities such as deforestation for the sake of cultivation, firewood and timber for building. Since 1955 vegetation cover has continued to be converted to farmland (sisal estates and mixed crops) and an extensive expansion of agriculture at the expense of the natural vegetation cover occurred between 1995 and 2000 (Yanda and Munishi 2007). On the other hand, a study by Ngoye and Machiwa (2004) showed impairment of the water quality of the river by anthropogenic activities in the catchment. Poverty, rapid increase in population and urbanization magnify water supply problems (Collignon and Vézina 2000; Mato 2002; Kjellen and McGranahan 2006; Opere 2010). In 2009, only 25 % of the population received water supplied by Dar es Salaam Water and Sewerage Authority (DAWASA) and much of the water needs were expected to be met through private boreholes (UN-HABITAT 2009).

Due to unreliability of water from Ruvu River and due to the fact that all rivers in Dar es Salaam City are polluted and the city’s limited capacity to expand its water supply system, this has resulted in increasing groundwater dependency. Over 50 % of residents rely on groundwater for drinking, irrigation and industrial purposes. More than 7,500 active boreholes/wells extracting water from DQCA exist in different localities of the city and annual exploitation of the aquifer has reached around 69.3 × 106 m3 (Mtoni et al. 2011). Despite the significant importance of groundwater in Dar es Salaam City, threats exist (Nkotagu 1989; Mato 2002; Chaggu 2004; Mjemah 2007; Mjemah et al. 2009, 2011; Dejager 2011; Van Camp et al. 2012; Bakari et al. 2012), which include: (1) groundwater over-abstraction that leads to the intrusion of seawater in freshwater aquifers; (2) poor sewerage system and (3) industrial waste disposal.

Objectives

To prevent further seawater intrusion and other contamination threats, that have already resulted in DQCA (Mato 2002; Mjemah 2007; Mtoni et al. 2012), it is crucial to examine closely the hydrogeochemical processes in the aquifer systems. The current study aims to define the principal hydrogeochemical processes controlling groundwater quality in DQCA in the coastal strip of Dar es Salaam and to investigate whether the threats of seawater intrusion and pollution are influencing groundwater quality.

Study area

The study area is located in the East African coast in Dar es Salaam City (Tanzania) bordering the Indian Ocean to the east. It extends from Mbezi River and Msasani Bay in the north to the area between Kizinga and Mzinga River system in the south (Fig. 1). Dar es Salaam City, which is the major seat of government institutions, is the largest urban centre in Tanzania and a major financial, commercial, manufacturing and transport hub. The city currently with a population of about 4 million people receives many visitors, and rural–urban migration makes it one of the fastest growing cities in the world, which in turn causes problems that are typical of a tropical megacity. Among others, these include sluggish infrastructural growth and poor sanitation. The high demographic and economic development activities taking place in Dar es Salaam occur along with environmental destruction that includes also deterioration of groundwater quality.

Fig. 1
figure 1

Location map of study area showing the geology and sampled points

Geology and hydrogeology

Several authors have studied the geology of coastal Tanzania (Alexander 1968; Kent et al. 1971; Msindai 1988; Mpanda 1997; Muhongo et al. 2000; Pearson et al. 2004; Mjemah 2007). The sediments in the coastal basin of Tanzania have ages ranging from Jurassic to Recent (Muhongo et al. 2000). The geological formations of the study area consist mainly of Quaternary and Neogene deposits (Fig. 2) (GST 1963). The Quaternary deposits are subdivided into: (1) alluvial deposits comprising clay, silt, sand and gravel, which are recent deposits occurring in river valleys; (2) coral reef limestone; and (3) sands of Pleistocene to Recent age with Holocene white buff sands at outcrop; these sands constitute the main aquifers of the study area (Mjemah 2007; Van Camp et al. 2012). The Neogene deposits at and around the study area are classified into two main groups: (1) the Mio-Pliocene clay-bound sands and gravels formation outcropping in the northwest, south-east and to the south, and underlying the Pleistocene to Recent deposits in most of the study area. They appear to be more clayey near their top whereas in deeper parts, the clay content may decrease, leading to a deep aquifer; and (2) the Lower Miocene Pugu Kaolinitic Sandstone occurring in the west. The latter consists of reddish brown, thick-bedded sandstone inter-bedded with minor siltstone, shale, and limestone.

Fig. 2
figure 2

Geological map of Dar es Salaam and the study area (GST: Geological Survey of Tanganyika 1963)

The inspection of lithological logs from the available groundwater drilling reports indicates that the study area is characterized by alternating layers of sands, clays, gravel and coral limestone of various degree of weathering. Within the unconsolidated Quaternary sand deposits (Fig. 3), the presence of the semi-pervious unit (clay, sandy clay and silts) allows two productive aquifers both of Quaternary age to be distinguished: an upper unconfined sand aquifer and a lower semi-confined sand aquifer. The lower aquifer overlies the substratum formed by Mio-Pliocene clay-bound sands. Closer to the coastline, there exists the limestone aquifer, comprising reef limestone of Pleistocene to Recent age, which is often in contact with the sandy aquifer, either underlying it or connected laterally. However, sandy aquifers are the most important in Dar es Salaam for supplying groundwater. The upper unconfined sand aquifer varies in thickness from 1 m near the ocean to about 25 m inland. The semi-confined aquifer varies greatly, from about 3 to 50 m. The thickness of the impervious layer separating the two aquifers also varies greatly, from about 6 to 35 m. Unconfined aquifer and semi-confined aquifer have average hydraulic conductivity values of 1.58 and 2.14 m/day, respectively (Mjemah et al. 2009). Due to the sandy nature of the subsoil in many parts of the city, sinking of boreholes/wells is easy and this has led to the increased supply of groundwater to complement the reticulated supply by surface water.

Fig. 3
figure 3

Cross-section A–A′ showing hydrogeological units and coastal terraces in Dar es Salaam Region: topographic elevation in the profile was taken from Msindai (1988). Location of the cross section is shown in Fig. 2

Topography and drainage

Dar es Salaam is situated in coastal lowland with extensive flat areas rising gently from the shore line to 15–20 m.a.s.l around the City Centre (Fig. 3). Inland alluvial plains are characterized by rivers originating from Pugu Hills to the west of the study area (Mjemah 2007; Van Camp et al. 2012). The coastal plain is elevated at about 0–10 m.a.s.l (Mtoni terrace), 10–50 m.a.s.l (Tanga terrace) and 50–130 m.a.s.l (Sakura terrace) (Fig. 3). The upland plateau comprises dissected land and the Pugu/Kisarawe Hills to the west. In the hydrogeological cross section in Fig. 3, the altitude at Pugu Hills ranges from 175 to 265 m.a.s.l. Pugu Hills are characterized by steep weathered slopes and ranges of kaolinitic sandstones: the underlying masses of sandstone with faults and joints are the permeable layers, for the water can penetrate readily through the faults and joints which as such provide features for remote recharge. DQCA system is a sand-filled Pleistocene valley cut in an underlying Mio-Pliocene heterogeneous complex of clay and sand alternations (clay-bound sands) (Van Camp et al. 2012). Its thickness increases from the west towards the sea in the east reaching about 150 m in the centre of the valley. Groundwater depths range from less than a metre near the coastline (Fig. 3) to more than 70 m (Van Camp et al. 2012) in the west. It is expected that along the borders of the Pleistocene valley there is inflow from the surrounding higher clay-bound sands areas and Pugu Hills. Apart from the lateral recharge from Pugu Hills and inflow from clay-bound sands areas, the study area receives direct infiltration from rainfall. The hydrographical network is such that rains/springs at Pugu Hills flow into streams which in turn flow into the main river systems (Mbezi, Msimbazi, Kizinga and Mzinga) running through the coastal plain and discharging into the Indian Ocean (Figs. 1 and 2). The average amount of rainfall in Dar es Salaam City is approximately 1,114 mm/year (average calculated based on data from 1971 to 2009) (Mtoni et al. 2011) with considerable variation. The major precipitation (78.6 %) occurs in two periods: long and heavy rains occurring in March to May with peak rainfall in the month of April, while short and light rains occur in October to December. The study area is mainly covered by sandy soils, which allow a high potential infiltration.

Regional groundwater flow is from west to east, where the Indian Ocean is the discharge boundary. Recharge to the local flow system is from the relatively flat land which slopes gently towards the sea. River channels play a major role in landscape evolution, setting the boundary conditions and are discharge areas for shallow groundwater. The study by Mjemah (2007) shows that the lithology of the drainage basin plays a major role in river flow: seasonal Mbezi River is located within the clay-bound sands area, favouring runoff and reducing groundwater recharge; perennial Kizinga River and Msimbazi River are located within the coastal plain, where the sandy sediments favour infiltration, such that groundwater can continue to discharge to the river, sustaining river flow during the dry season; Mzinga River, on the border of the coastal plain and the clay-bound sands area, undergoes both influences.

Research methodology

A total of 134 duplicate groundwater samples from boreholes and hand dug wells were collected (between 2009 and 2010) from each sampling point for major ions determination in the laboratory. The groundwater samples were taken after pumping the boreholes. As all boreholes were regularly being used, it was not necessary to include a long pre-pumping period. The temperature (T °C), pH, and electrical conductivity (EC) were measured in the field. Samples were collected and stored below 4 °C and analysed in the Laboratory for Applied Geology and Hydrogeology of Ghent University, Belgium. Chemical analyses of major ions (Ca2+, Mg2+, Na+, K+, Fe2+, Mn2+, NH4 +, Cl, SO4 2−, HCO3 , CO3 2−, NO3 , NO2 , PO4 3−, F and B) were carried out. Quantification of the cations Na+, K+, Ca2+, Mg2+, Fe2+ and Mn2+ was done by flame atomic absorption spectrometry (FAAS). Molecular absorption spectrophotometry (colorimetry) was used to determine the concentrations of Cl, NH4 +, NO3 , NO2 and PO4 3−. The concentration of HCO3 and CO3 2− was determined by titration with HCl. SO4 2− was measured with a turbidimetric method and F and B with ion selective electrodes. The reliability check of the quality of the laboratory analysis was done by the following formula:

$$ {\text{Error on ionic balance}} \;(\% ) = 100 \times \frac{{\mathop \sum \nolimits {\text{cation}} - \mathop \sum \nolimits {\text{anion}}}}{{\mathop \sum \nolimits {\text{cation}} + \mathop \sum \nolimits {\text{anion}}}}. $$

The analysis is considered as reliable if the error on the ion balance is smaller than 5 %. The error for all analyses was less than 5 %. The hydrochemical results were analysed by means of Aquachem software (Calmbach 1997), the Piper (1944) diagram and the Stuyfzand (1986) classification. The Piper diagram was used to plot the major ions as percentages of milli-equivalents. Piper diagram provides a convenient method to classify and compare water types based on the ionic composition of different water samples. The classification by Piper diagram helps to understand the several geochemical processes occurring along the flow path of the groundwater. On the other hand, water classification by Stuyfzand (1986, 1993) method involves subdividing the most important chemical water characteristics at four levels: the primary type, type, subtype, and class (Table 1). The primary type is determined based on the chloride content (F = fresh: Cl < 150 mg/l; Fb = fresh − brackish: 150–300 mg/l; B = brackish: 300–1,000 mg/l; Bs = brackish − salt: 1,000–10,000 mg/l and S = salt: 10,000–20,000 mg/l). The type (code) is determined on the basis of total hardness [very soft (*): Ca + Mg < 0.5 mmol/l; soft (0): 0.5–1 mmol/l; moderately hard (1): 1–2 mmol/l; hard (2): 2–4 mmol/l; very hard (3): 4–8 mmol/l; extremely hard (4–7): >8 mmol/l] (Table 1). The classification into subtypes is determined based on the dominant cations and anions. Finally, the class is determined on the basis of the sum of Na+, K+ and Mg2+ (meq/l), corrected for a seawater contribution, determined from the Cl content (Table 1).

$$ ({\text{Na}} + {\text{K}} + {\text{Mg}})_{\text{corrected}} = ({\text{Na}} + {\text{K}} + {\text{Mg}})_{\text{measured}} - 1.061 {\text{Cl }}({\text{meq/l}}). $$
Table 1 Classification of water based on chloride concentration, hardness and correction for a seawater contribution: Stuyfzand (1986) classification

This parameter is further tested against \( \sqrt {0.5} {\text{Cl}} \) as a margin of error in order to conclude to a meaningfully positive (marine cations surplus; positive cation exchange code), negative (marine cations deficit; negative cation exchange code) or equilibrium value (cation exchange code Ø) (Table 1). This classification enables to recognize if cation exchange has occurred in a water sample.

In order to study the chemical equilibrium existing in groundwater from the study area, the concept of speciation modelling was used. Important results of speciation calculations are saturation indices (SI) for minerals, which indicate whether a mineral should dissolve or precipitate. Saturation indices of some common minerals were calculated using the program PHREEQC (Parkhurst and Appelo 1999). World Health Organization (WHO) (2004) guidelines for drinking water quality were used for the assessment of drinking water quality. Sodium adsorption ratio (SAR), soluble sodium percent (%Na), electrical conductivity (EC) and other parameters such as chloride and sulphate were used for irrigation suitability assessment. Groundwater suitability was interpreted by using the US Salinity Laboratory (USSL) (1954) diagram.

Results and discussion

Composition of major ions

Statistical analysis of various chemical constituents is presented in Table 2. Na+ is dominant among the major cations in both unconfined and semi-confined aquifers. In unconfined aquifer water samples, it ranges from 2.1 to 10,000 mg/l and represents on average 77.77 % of all cations. In the semi-confined aquifer, Na+ ranges from 14.6 to 2,492.5 mg/l representing on average 67.76 % of all cations. 47.14 % of samples from the unconfined aquifer and 21.88 % of the semi-confined water samples are beyond the permissible limit of WHO (2004) for Na+.

Table 2 Statistical summary of hydrochemical parameters of groundwater (n = 134: 70 samples from the unconfined aquifer and 64 samples from the semi-confined aquifer)

Ca2+ and Mg2+ cations are of secondary importance in both unconfined and semi-confined aquifers. In the upper aquifer, Ca2+ and Mg2+ represent an average of 10.54 and 8.27 % of all cations, respectively, whereas in the lower aquifer these cations represent, respectively, an average of 16.84 and 8.29 % of all cations. K+ is minor representing on average 2.42 % of all cations in the upper aquifer and 7.13 % in the semi-confined aquifer. For the anions, Cl, HCO3 , SO4 2− and NO3 ions represent on average 73.03, 14.71, 7.76 and 4.44 % of all anions in the unconfined aquifer, respectively. In the semi-confined aquifer, the same anions represent on average 51.56, 26.37, 14.21 and 7.87 %, respectively.

Cl ranges from 6.4 to 15,478 and 14.1–4,745.2 mg/l in unconfined and semi-confined aquifers, respectively. 50 % of samples from the unconfined aquifer and 30 % of semi-confined water samples exceed the permissible limit for Cl. SO4 2− ranges from 2.1–1,063.9 and 0.66–703 mg/l in unconfined and semi-confined aquifers, respectively. 18.57 % of samples from the unconfined aquifer and 6.25 % of semi-confined aquifer water samples exceed the permissible limit for SO4 2− of WHO (2004). NO3 ranges from 0.0–435.4 and 0.04–351.3 mg/l in unconfined and semi-confined aquifers, respectively. 47.14 % of samples from the unconfined aquifer and 28.13 % of semi-confined aquifer samples are beyond the permissible NO3 limit of WHO (2004).

The correlation coefficient of the studied parameters is shown in Table 3. A significant correlation is observed between Na+ and Cl (0.985) and between Mg2+ and Cl (0.914), due to seawater intrusion. Poor correlation (0.35) was observed between Ca2+ and Cl. From the data obtained, concentration of calcium ions is much lower compared to chloride ions which can be an indication of calcium removal as a result of calcite precipitation. Precipitation takes place during the cation exchange process which is the later effect from the seawater intrusion into the aquifer: Ca2+ in the aquifer matrix is exchanged with Na+, the water becomes supersaturated with respect to calcite. The positive correlation of K+ with both Cl and SO4 2−, which are all high in seawater, may be interpreted in the light of seawater intrusion as well. The positive correlation between Ca2+ and Mg2+ (0.471) is attributed to the dissolution of calcite and dolomite. Positive correlation (0.424) also exists between Ca2+ and SO4 2− and as well as between Mg2+ and SO4 2− (0.409). The main inputs of SO4 2− and also NO3 to groundwater are derived from anthropogenic activities. Pollution sources are from the wastewater discharged from the industries and through the use of pit latrines/septic tanks.

Table 3 Correlation matrix for all data (n = 134)

Saturation indices

Saturation index (SI) calculations of some common minerals using the program PHREEQC (Parkhurst and Appelo 1999) were employed to determine whether a mineral species is likely to dissolve or precipitate in a groundwater flow system. It is postulated that mineral phases that are clearly undersaturated (SI ≤ −0.1) will tend to dissolve and mineral phases that are clearly oversaturated (SI ≥ +0.1) will precipitate these mineral phases out of solution (Adams et al. 2001); equilibrium is taken to be between SI = −0.1 and +0.1. The saturation indices of some common carbonate minerals (aragonite, calcite and dolomite), sulphate minerals (gypsum and anhydrite) and halite are shown in Table 4. All samples were undersaturated with respect to anhydrite, gypsum and halite. These minerals were not observed in the study area. Aragonite, calcite and dolomite are distributed around saturation equilibrium (i.e. oversaturated to undersaturated). 40, 40 and 42 % of the samples were undersaturated, respectively, with respect to aragonite, calcite and dolomite. The processes of dissolution, precipitation and cation exchange are actively taking place within the groundwater system. The dissolution of minerals and the subsequent exchange between cations can lead to the precipitation of minerals.

Table 4 Percentages of samples with saturation indices subdivided into 3 classes (undersaturated, in equilibrium, supersaturated) obtained from PHREEQC analysis

Bivariate scatter plots

From the scatter plots, it can be deduced that the chemical composition of groundwater in the study area in general is influenced by seawater intrusion. In the current study, the molar ratio of Na+/Cl for analysed samples ranges from 0.41 to 2.80 with an average value of 0.93. The deviation of the calculated molar ratio of Na+/Cl from the Na+/Cl molar ratio of the seawater (0.86) (HydroMetrics 2008) is indicated in Fig. 4a. The seawater dilution line in Fig. 4b shows simple mixing of both end members freshwater and seawater as shown by the Na+ and Cl ion concentration. A deviation from the mixing line could be ascribed to ion exchange processes, indicating an excess or depletion of Na+ relative to Cl (Walraevens and Van Camp 2005). Excess Na+ in water plotting above mixing line in Fig. 4b indicates freshening and it corresponds to samples with lower Cl in Fig. 4a (Walraevens et al. 1998). On the other hand, depletion of Na+ in water plotting below mixing line in Fig. 4b indicates salinization and it corresponds to samples with high Cl in Fig. 4a. The Na+/Cl ratio could reach unity due to the mixing of seawater and freshwater, which has a Na+/Cl ratio greater than unity (Vengosh et al. 1999, cited in Ghabayen et al. 2006). The Na+–Cl bivariate plot (Fig. 4b) demonstrates a distinct strong correlation between Na+ and Cl concentrations for most of the samples indicating saltwater intrusion, as admixture of the saline end member is increased. As already explained, under the conditions of saline intrusion, Na+ in seawater replaces Ca2+ adsorbed onto the surface of clays and this results in a relative depletion of Na+ in groundwater. Thus, Na+ values for some samples are decreased and are plotted below the mixing line. Levels of Cl and electrical conductivity (EC) are the simplest indicators of seawater intrusion or salinization (El Moujabber et al. 2006). Contamination by seawater leads to the elevated Cl and EC values. Generally, fresh groundwater that is not affected by pollution is characterized by low values of EC, Cl and Ca–Mg–HCO3 water type. The latter represents freshwater that has recently infiltrated into the zone of recharge, while the EC and Cl show a gradual increase from the uplands (recharge areas) towards the lowlands (discharge areas). Along the coastline, high values of EC and Cl are attributed to salinization by seawater intrusion. The groundwater EC and Cl values range from 138.4–2,200 μS/cm and 6.2–353 mg/l at distances greater than 2 km away from the coastline, to about 760–19,200 μS/cm and 72–15,478 mg/l at a distance of less than 2 km from the coastline, respectively. The former are related to areas such as Mbagala, Mtoni, Kurasini, Ilala and Mwananyamala, whereas the latter are related mainly to the areas close to the coastline such as City Centre, Oysterbay and Msasani (Fig. 7).

Fig. 4
figure 4

Scatter diagram of: a log Na+/Cl ratio versus log Cl; b log Na+ versus Log Cl; and c log Cl/HCO3 ratio versus Log Cl (mg/l)

In the bivariate diagram of Cl/HCO3 versus Cl (Fig. 4c) some samples have much higher ratios compared to the others. The ratio of Cl/HCO3 ranges between 0.13 and 198.70. The effect of salinization of the groundwater was classified using the Cl/HCO3 ratio <0.5 for unaffected groundwater, 0.5–6.6 for slightly and moderately affected, and >6.6 for strongly affected groundwater (Revelle 1941). Considering the values of Cl concentration and the ratio Cl/HCO3, 14 % of groundwater samples are unaffected, 63 % of groundwater samples are slightly or moderately affected and 23 % are strongly affected by the saline water. 64 % of unaffected water samples are from boreholes/wells drilled away from the coastline (>2 km) and are characterized as fresh groundwater, whereas 67 % of strongly affected water samples are from the wells drilled towards the coastline (<2 km).

The geochemistry of the aquifer system in the study area is also contributed by the dissolution of calcite. Figure 5a shows the relationships 2:1 and 1:1 between HCO3 and Ca2+, respectively, corresponding to the following reactions:

Fig. 5
figure 5

Scatter diagram of: a HCO3 versus Ca2+; b (HCO3 ) versus (Ca2+ + Mg2+); and c log Mg2+/Ca2+ versus log Na+/Ca2+

Typical dissolution of calcite by CO2 in the unsaturated zone:

$$ {\text{CaCO}}_{3} + {\text{CO}}_{2} + {\text{H}}_{2} {\text{O}} \to {\text{Ca}}^{2 + } + 2{{\text{HCO}}_{ 3}}^{ - }. $$
(1)

Calcite dissolution by other acids apart from CO2 (e.g. humic acids, protons released from cation exchange) Walraevens (1990).

$$ {\text{CaCO}}_{3} + {\text{H}}^{ + } \to {\text{Ca}}^{2 + } + {{\text{HCO}}_{ 3}}^{ - }. $$
(2)

Figure 5a suggests that, at lower Ca2+ concentrations (<4 mmol/l), the first reaction (1) seems to be preferred, although the spread is large. At higher Ca2+ concentrations, the second reaction (2) seems to be preferred.

When dolomite is present, this mineral may dissolve according to the reaction:

$$ {\text{CaMg}}({\text{CO}}_{3} )_{2} + 2{\text{CO}}_{2} + 2{\text{H}}_{2} {\text{O}} \Leftrightarrow {\text{Ca}}^{2 + } + {\text{Mg}}^{2 + } + 4{{\text{HCO}}_{ 3}}^{ - }. $$
(3)

If dolomite dissolves according to reaction 3, the relation of [Ca + Mg] to [HCO3] should be linear, with a slope of 2 (Fig. 5b). In the study area groundwater samples are highly enriched in Ca2+ and Mg2+ relative to HCO3 . If all calcium and magnesium were derived from calcite and dolomite dissolution, samples would plot along the equiline. Many points fall far below the equiline, signifying an additional source of calcium. Other sources of Ca2+ and Mg2+, in groundwater can be enrichment of Ca2+ by cation exchange, saltwater intrusion raising Mg2+ and weathering of calcium and magnesium minerals. Cation exchange processes result in a deficit of marine cations and a surplus of the freshwater cation Ca2+ (reaction 4): this leads to the development of the Ca–Cl water type, which is typical for salinization (Walraevens and Van Camp 2005).

$$ 2{\text{Na}}^{ + } + {\text{Ca}}X_{2} \leftrightarrow {\text{Na}}{-}{\text{X}} + {\text{Ca}}^{2 + }. $$
(4)

The Mg2+/Ca2+ and Na+/Ca2 ratios (in meq/l) of seawater is about 5 and 22.5, whereas in freshwater is about 1 and 1.7, respectively. In the study area values of Mg2+/Ca2+ (av. 0.92) and Na+/Ca2 (av. 4.70) are much lower than those of seawater, which supports the idea of Ca2+ enrichment and depletion of Mg2+ and Na+ caused by cation exchange during mixing with saltwater. On the other hand, the possibility for addition of Ca2+ can occur through weathering of silicate minerals such as calcium plagioclase (anorthite) (reaction 5). The contribution of silicate minerals can be understood through the variation of the composition of water Mg/Ca versus Na/Ca (Han and Liu 2004). Groundwater samples plot close to silicate rocks with influence of carbonate rocks (Fig. 5c), reflecting the involvement of silicate minerals.

$$ \mathop{{\text{CaAl}}_{2} {\text{Si}}_{2} {\text{O}}_{8}}_{\hbox{Anorthite}} + 2{\text{H}}_{2} {\text{CO}}_{3} + {\text{H}}_{2} {\text{O}} \to \mathop{{\text{Al}}_{2} {\text{Si}}_{2} {\text{O}}_{5} ({\text{OH}})_{4}}_{\hbox{Kaolinite}} + 2{{\text{HCO}}_{3}}^{ - } + {\text{Ca}}^{2 + } $$
(5)

Groundwater classification

Groundwater samples were classified according to the Stuyfzand (1986) and Piper (1944) classification systems (Table 5).

Table 5 Water type classification according to Piper (1944) and Stuyfzand (1986) methods

Piper diagram

From the analysis of the Piper diagram (Fig. 6a) Cl and HCO3 are the dominant anions whereas Na+ and Ca2+ are the most dominant cations. Although the Piper diagram shows several water types (Table 5) are present in the groundwater system in the study area, the dominant groups include Na–Cl, Ca–HCO3, Na–Ca–Cl and Na–HCO3. Samples with Na–Ca–Cl water type plotting above the mixing line (signifying effect of salinization) are dominant in the unconfined aquifer comparing to the semi-confined aquifer. Samples from both unconfined and semi-confined aquifer, plotting below the mixing line, are signifying both mixing and freshening processes.

Fig. 6
figure 6

a Piper diagram with classification of major ions and groundwater types in the study area. b Piper diagram showing boreholes/wells located in close proximity to the coastline (<2 km) and further from coastline (>2 km)

Cation exchange is one of the most important factors modifying groundwater quality and as well one of the most significant geochemical processes taking place in aquifers affected by salinization or freshening (Al Farrah et al. 2011; Walraevens and Van Camp 2005; Cruz et al. 2011). In coastal aquifers, where the relationship between seawater and freshwater is complex, cation exchange contributes significantly to the final composition of the groundwater (Walraevens and Van Camp 2005): the ion exchange reaction (reaction 4) of Na+ and Ca2+ often occurs when seawater intrudes fresh groundwater. When seawater intrudes a fresh groundwater aquifer, Na+ is adsorbed and Ca2+ is released into the water. This process leads to the change of NaCl water type to the CaCl water type (Walraevens and Van Camp 2005; Imerzoukene et al. 1994). The opposite process takes place with re-freshening of groundwater. It is quite well known that the displacement of seawater by freshwater in an aquifer is shown by a NaHCO3 type water (Stuyfzand 1993; Walraevens et al. 1992, 2007; Coetsiers et al. 2009; Blaser et al. 2010a, b). Ca2+ from fresh CaHCO3 water type exchanges with adsorbed Na+.

The freshwater’s end member has a CaHCO3 major ion composition. Formation of NaHCO3 water types, provide evidence of freshening. Brackish and saline groundwater samples appearing in the mixing line have a Na–Ca–Cl major ion composition. Dissolution of calcite and dolomite in recharge areas results in fresh Ca–HCO3 and Ca–Mg–HCO3 groundwater types. Further along flow paths, Ca2+ and Na+ ion exchange causes groundwater evolution to Na–HCO3 type. Samples of most of the boreholes located close to the coastline plot in the NaCl area while those located further from the coast appear to plot in the freshwater mixing line (Fig. 6b). Chloride concentration shows a general increase down gradient to the east towards the coastline (Fig. 7): Cl values range from 6.4 to 15,478 mg/l. This further indicates that groundwater in close proximity of the coast is influenced by the intrusion of seawater.

Fig. 7
figure 7

Chloride distribution in the study area

Apart from saltwater intrusion, the Piper diagram furthermore reveals that the hydrogeochemical composition of some groundwaters in some areas is affected by nitrate contamination, evidenced by the Na(Mg,Ca)–NO3 water type. Excessive nitrate concentrations in groundwater of the study area are the result of contamination by wastewater from pit latrines and leakage from septic tanks. This problem is mainly affecting the unconfined aquifer. Figure 8 shows nitrate distribution in the study area. High nitrate concentrations have been encountered in various parts of the aquifer especially in the high-density housing settlements. Nitrate levels of 50–100 mg/l within the City Centre can be related to the leaking from the unrehabilitated aging sewerage system. Nitrate values of 100–200 and >200 mg/l in dense informal settlements reflect the existence of high to very high density of pit latrines, respectively. The study which was done by Mato (2002) about a decade ago reported high values of nitrates above 100 mg/l in the study area. This included areas such as Ilala and Buguruni which showed elevated levels of up to 151 mg/l, Keko and City Centre areas values ranging from 74 to 108 mg/l. A study conducted by Mjemah (2007) 5 years later reported a maximum value of nitrate of 421 mg/l in Mbagala area (Fig. 8). The current study has shown values of nitrate ranging from 0 to 435 mg/l, the maximum value observed at Kawe (Fig. 8) in a shallow well (unconfined aquifer). Although water samples were not taken in the same boreholes in previous studies, it indicates groundwater pollution by nitrate mainly shows an increasing trend, reflecting the increased use of pit latrines and leakage from the unrehabilitated sewage system.

Fig. 8
figure 8

Nitrate distribution in the study area

Stuyfzand water type classification

The chloride concentration of the samples has a wide range from 6.42 to 15,478 mg/l, ranging from fresh to salt (Table 5). The majority of the samples accounting to 54 % are grouped as fresh (F). The second most important class is brackish for 21 % of samples.

In the study area, the total hardness varies through a wide range from very soft (0.46 mmol/l) to extremely hard (90.6 mmol/l). However, it is clear that most of the samples are hard (30.6 %), or very hard (26.8 %). Generally, these high values of total hardness are related to the dissolution of carbonate (calcite and dolomite) yielding high concentrations of Ca2+ and Mg2+ (Appelo and Postma 1993).

Groundwater was classified into several categories based on dominant cation and anion, i.e., sodium-chloride, sodium-bicarbonate, calcium-bicarbonate, magnesium-bicarbonate, sodium-mix and calcium-mix. Most of shallow wells close to the shoreline have “Brackish-saline extremely hard NaCl” to “Brackish very hard CaCl” water.

Table 5 shows the Stuyfzand (1986) classification results of the groundwater samples analysed from the study area. It is observed that most samples have a positive cation exchange code. This would refer to freshening. However, the concept supposes that the only freshwater cation is Ca2+, while Mg2+ is only contributed by the seawater end member. In the study area, this assumption is not valid: part of the Mg2+ derives from dolomite dissolution. Therefore in the study area, the corrected sum of marine cations is increased by the dolomite-derived Mg2+, upgrading the cation exchange code. Water samples, affected by active salinization can therefore show equilibrium, or even a positive cation exchange code, instead of the expected negative code. Dissolution of calcite, dolomite and/or Mg2+ bearing calcite is an important process in most groundwaters (Al Farrah et al. 2011; Morse and Mackenzie 1990). The same process of saltwater intrusion has been established in many other coastal regions (Trabelsi et al. 2012; Ahmed et al. 2012; Reddy 2012). A study conducted in Libya (Al Farrah et al. 2011) gives a comparable example to this study: the water types indicated that groundwater chemistry is changed by cation exchange reactions during the mixing process between freshwater and seawater.

Processes affecting groundwater quality

Hydrogeochemical data on dissolved major cations and anions analysed in groundwater samples reveal the main processes responsible for their geochemical evolution. Groundwater is mainly affected by four factors: (1) dissolution of calcite and dolomite in recharge areas; (2) weathering of silicate minerals; (3) seawater intrusion due to aquifer overexploitation; and (4) nitrate pollution mainly caused by the use of on-site sewage disposal systems, in particular pit latrines and septic tanks, as well as by the leaking sewerage system in the City Centre.

Suitability of groundwater quality for different uses

Groundwater in Dar es Salaam is used for domestic, industrial and irrigation purposes. The domestic water used for drinking should comply with WHO standards. Irrigation water is tested based on the sodium absorption ratio (SAR), EC, soluble sodium percent (SSP), Cl and SO4 2−. These evaluations will be made in the following section. Required groundwater quality for industrial purposes depends on the different industrial uses, and cannot be generalized. However, high salinity is undesirable.

Groundwater quality for drinking purposes

The unregulated boreholes/wells and the virtually unregulated abstraction of groundwater, have exacerbated the declining water quality situation as a result of saline water intrusion. The depths of the sampled boreholes range from 7 to 100 m (Fig. 9). Groundwater types are from the inland toward the coast: Ca-mix, Na-mix, and NaCl, showing increasing influence of salinity. Groundwater samples collected in most of the boreholes drilled more inland show good quality of water in regard to salinity. Most of the boreholes near the coastline are drilled at shallow depth to minimize the possibility of meeting saline water. In areas close to the coastline such as Msasani, Oysterbay and City Centre, in 60 % of sampled boreholes, drilling depths range from 10 to 20 m. These boreholes are located within a distance of 1.5 km from the ocean. Samples from these boreholes show elevated chloride and sodium concentrations and comprise about 83 % of the total samples which are beyond the permissible chloride and sodium limits of WHO (2004) (Table 1). Due to their high solute concentrations, they are not suitable for domestic purposes, as they do not comply with the limits set by the WHO. The effect of salinization is greatest in the City Centre for boreholes drilled within 1 km from the ocean (Mtoni et al. 2012). The situation is expected to worsen over the coming years, due to the increasing trend of groundwater dependence for water supply.

Fig. 9
figure 9

Drilling depth versus boreholes/wells number

Apart from chlorides, other main contaminants encountered in groundwater are nitrate and sulphate. Based on the permissible nitrate and sulphate limits of WHO (2004) (Table 2), 38 and 12.68 % of all samples from the study area are regarded as unsuitable, respectively. Improper disposal of solid and liquid wastes is leading to groundwater contamination. From the results of water analysis it is observed that shallow boreholes contain higher nitrate and sulphate than deeper ones (Table 2). This implies that the shallow aquifer is more vulnerable to anthropogenic pollution than the lower aquifer. This is of particular concern to the people who use shallow drinking water wells that can be easily contaminated. About 75 % of the city’s residents live in unplanned and un-serviced settlements. General characteristics of these settlements include high population density, overcrowding, haphazardly laid out infrastructure and poor provision of basic services such as water supply and sanitation. Mainly residents living in these settlements use shallow wells for water supply and as well use pit latrines/septic tanks which are usually poorly constructed, causing health and major environmental problems.

Groundwater quality for irrigation purposes

The United States Department of Agriculture (USDA) (1954) classifies irrigation water with respect to its SAR. SAR is calculated from the following formula, all concentrations expressed in milli-equivalents per litre:

$$ {\text{SAR}} = \frac{{{\text{Na}}^{ + } }}{{\sqrt {\frac{{{\text{Ca}}^{2 + } + {\text{ Mg}}^{2 + } }}{2}} }}. $$

The waters having SAR values less than 10 are considered excellent, 10–18 as good, 18–26 as fair, and above 26 are unsuitable for irrigation use (USDA 1954) (Table 6) (Fig. 10). Wilcox (1955) diagram (Fig. 10) is widely used and is especially implemented to classify groundwater quality for irrigation (Ebraheem et al. 2012; Banoeng-Yakubo et al. 2009; Ganyaglo et al. 2011; Swarna Latha and Nageswara Rao 2012). The calculated SAR ranges from 0.11 to 93.40 in groundwater in the study area and almost all samples fall into excellent and good classes, except 8 samples which fall into doubtful and unsuitable class (Table 5). The USDA (1954) has also classified irrigation waters on the basis of electrical conductivity (EC) as indicated in Table 6. Most samples in the study area fall into medium, high and very high salinity water (Table 6) (Fig. 10).

Table 6 Classification of irrigation water according to USDA (1954)
Fig. 10
figure 10

Groundwater suitability for irrigation in the study area. Assessment was conducted using Wilcox (1955) diagram

Soluble sodium percentage (%Na) was also used to evaluate sodium hazard. %Na is defined as the ratio of sodium to the total cations. Water with %Na greater than 60 % may result in sodium accumulations that will cause a breakdown in the soil’s physical properties (Khodapanah et al. 2009). %Na determines the ratio of sodium to total cations including sodium, potassium, calcium and magnesium. All concentration values are expressed in milli-equivalents. %Na is calculated as follows:

$$ \%\,{\text{Na}} = \frac{\text{Na}}{{{\text{Na}} + {\text{K}} + {\text{Ca}} + {\text{Mg}}}} \times 100. $$

The values for %Na in the study area range from 5.96 to 90.60 %. It is observed that 58 samples have very high sodium percentage (above 60 %) (Table 7).

Table 7 Classification of water based on percent sodium (%Na)

Other parameters such as chloride and sulphate have been also used for assessment of suitability of water for irrigation (Sagnak 1991; Bauder et al. 2004; Hopkins et al. 2007). Chloride is an essential element for plants and also an important criterion for irrigation water. Sulphate is necessary for plant nutrition, but water containing more than 1,000 ppm of sulphate has a disadvantage for plants with respect to absorbing of calcium (Sagnak 1991). It is observed that 79 samples with respect to chloride concentration fall into excellent and good classes, while 17 samples fall into permissible class. 38 samples are considered to be doubtful or unsuitable (Table 8). For sulphate concentration, 124 samples fall into excellent and good classes, while 7 samples fall into permissible class. Only three samples are considered to be doubtful or unsuitable (Table 8).

Table 8 Irrigation water classes based on chloride and sulphate contents

According to USSL’s diagram (US Salinity Laboratory Staff 1954), which is widely used for rating the irrigation waters, water can be grouped into 16 classes. It uses SAR (vertical axis) and specific conductance (horizontal axis) (Fig. 10) (Table 9). The conductivity (horizontal axis) is classified into low (C1), medium (C2), high (C3) and very high (C4) salinity zones. These zones (C1–C4) have the value of EC <250, 250–750, 750–2,250 and >2,250 μS/cm, respectively. The SAR (vertical axis) is subdivided into four classes, with decreasing limiting values as EC increases: low (S1), medium (S2), high (S3) and very high (S4) sodium hazard. Significance of classes in relation to EC and SAR is presented in Table 10. The overall results based on the use of USSL’s diagram are presented in Tables 9 and 10. The results show that 56 % of all samples from the study area was graded as suitable for irrigation use, while 31 % as unsuitable. 13 % of samples were regarded as suitable under specific conditions. Groundwater samples classified as C2S1, C3S1, C3S2 and C4S4 were the dominant classes.

Table 9 Groundwater quality results using USSL diagram for 134 samples
Table 10 Summary of groundwater classification based on USSL diagram (134 samples)

Conclusions and recommendations

Conclusions

Results from the hydrogeochemical investigation in the study area indicate that the Dar es Salaam quaternary coastal aquifer (DQCA) is experiencing contamination primarily by seawater intrusion due to overexploitation and the use of on-site sewage disposal systems, in particular pit latrines and septic tanks. Seawater intrusion is limited to the area nearby the coast, whereas pollution by sewage is more widely spread. Dissolution of calcite/dolomite minerals in the aquifer matrix in the recharge areas, weathering of silicate minerals, as well as cation exchange also modify the concentration of ions in groundwater.

The study area can be divided into two areas based on the lithology: (1) coastal strip, the area adjacent to the ocean with reef limestone; (2) inland area adjacent to the coastal strip which consists of sands and clay. Saturation indices indicate the geology in the study area has a potential influence on the saturation status towards carbonate minerals. Most of the groundwater samples from the coastal strip range from equilibrium to oversaturation with respect to carbonate minerals (calcite and dolomite). However, all groundwater samples are undersaturated with respect to sulphate minerals (gypsum and anhydrite) and halite.

The hydrogeochemical results show that different processes determine major ionic composition of groundwater in the study area. The distribution pattern of major ions shows compositional variation in the groundwater samples. In general, the concentration of cations decreases in the order Na > Ca > Mg > K and of anions in the order Cl > HCO3 > SO4 > NO3. However, HCO3 dominates over Cl in some samples. Correlation analysis indicates that most of the ions are positively correlated. The reasonably good correlation among the ions especially Na+, Cl, and Mg2+, indicates that such ions are mainly derived from the same source of saline waters. This implies that the salinization of the study area occurring near the coastline is associated with seawater.

High electrical conductivity (EC) and chloride (Cl) concentration values decrease away from the coastline. Fresh groundwater that is not affected by pollution is characterized by low values of EC and Ca–Mg–HCO3 or Ca–HCO3 water type. Hydrogeochemical data of shallow well samples are dominated by Na–Ca–Cl type with Cl as the dominant anion, due to the effect of seawater intrusion. The deep groundwaters are slightly to moderately mineralized and are of Na–HCO3 type induced mainly by ion exchange reactions.

Over-abstraction of groundwater to meet freshwater demand has contributed to the deterioration of the water quality by seawater intrusion. Most boreholes located close to the coastline, due to their high solute concentrations, are not suitable for domestic purposes. The increase of salinization limits the application of groundwater for both domestic and irrigation purposes. Furthermore, high levels of nitrate and sulphate, observed especially in the shallow aquifer, due to lack of proper sanitation do not comply with the limits set by WHO.

The salinity and sodicity hazards of groundwater of DQCA were mainly classified as C2S1, C3S1, C3S2 and C4S4, i.e., high salinity with medium sodicity problems. Other factors such as soil and crop types need to be considered, since they play an important role in deciding on the suitability of water for irrigation.

Recommendations

These research results are useful for making better groundwater protection and exploitation plans for limiting the increasing saltwater intrusion and anthropogenic aquifer contamination. Application of rational groundwater management practices, including the decrease of pumping rates, is crucial in attaining the sustainability of groundwater resources in the study area. Establishing a groundwater monitoring programme close to the coast is equally important, based on which, measures may be taken to avoid the advancement of seawater intrusion on a large scale. Analyses of bromide would allow determining Br/Cl ratios that help to identify sources of salinity.

Lack of data, knowledge and capacity hinder sustainable management of groundwater resources. Sustainable groundwater management is needed and will require restriction of well development and appropriate monitoring of potential saltwater intrusion, particularly near the coastline. Given the highly specialized nature of the field of seawater expertise, there is great need for the training of hydrogeologists for effective monitoring, evaluation and management of coastal aquifers.