A two-dimensional model for biofilm growth and detachment was used to evaluate the effect of detachment on biofilm structures. The detachment process is considered to be due to internal stress created by moving liquid past the biofilm. This model generated a variety of realistic biofilm-formation patterns. It was possible to model in a unified way two different biofilm detachment processes, erosion (small-particle loss), and sloughing (large-biomass-particle removal). The distribution of the fraction from total biomass detached as a function of detached particle mass, gives indications about which of the two mechanisms is dominant. Model simulations indicate that erosion makes the biofilm surface smoother. Sloughing, in contrast, leads to an increased biofilm-surface roughness. Faster growing biofilms have a faster detachment rate than slow-growing biofilms, under similar hydrodynamic conditions and biofilm strength. This is in perfect accordance with the experimental evidence showing that detachment is dependent on both shear- and microbial-growth rates. High growth rates trigger instability in biofilm accumulation and abrupt biomass loss (sloughing). Massive sloughing can be avoided by high liquid shear, combined with low biomass growth rates. As the modeling results show, the causes for sloughing must be sought not only in the biofilm strength, but also in its shape. Several "mushroom-like" biofilm structures like those repeatedly reported in the literature occurred, due to a combined effect of nutrient depletion and breaking at the colony base. A rough carrier surface promotes biofilm development in hydrodynamic conditions in which the biofilm on a flat surface would not form. Although biofilm patches filled completely the cavity in which they started to grow, they were unable to spill over the carrier peaks and to fully colonize the substratum.