Strain localisation by shear banding in soft rocks and hard soils is studied experimentally and theoretically.The experimental work concerns three different materials: a Vosges sandstone, a stiffer silty rock from Gard (France) and a soft marl. The first part of this work involves a description of a new triaxial cell and the development of an internal strains measuring device. Following this, a set of tests on a Vosges sandstone confined at pressures up to 60 MPa are presented. The study concerns the homogeneous behaviour of the rock in compression, extension and isotropic stress paths, the detection of the onset of strain localisation, the characterisation of the localisation pattern by a macroscopic observation, a X rays CT measurement and by a quantitative microstructural analysis. The evolution of fracture from the initiation stage to the failure of the specimen is studied by using the false relief stereophotogrammetry in a silty rock from Gard, which is stiffer than the Vosges sandstone. For the Beaucaire marl (France), the normally consolidated behaviour is explored with measurements of the permeability during the deformation, in isotropic or deviatoric stress paths.The theoretical work presents the new constitutive law CloE-Rock specifically developed for soft rocks, from the model of hypoplastic non linear incremental laws CloE. It takes into account a mean pressure dependency on the volumetric behaviour of the material. The identification of the law is made on the Vosges sandstone studied in the first part. A parametric analysis of an explicit criterion of bifurcation in localised mode is performed to calibrate the theoretical results in comparison with the experimental measurements of the critical stress and strain at the onset of localisation and the shear band's orientation. This step shows the philosophy behind using the constitutive law, which considers the observation of the localisation to provide a calibration of the law's parameters.