This paper describes the determination of the hardness and the Young's modulus of β-Ga2O3 single crystals and epitaxial layers by nanoindentation technique. The measurements were performed on (100) plane of β-Ga2O3 single crystals produced by free crystallisation method and on (-311) and (-201) planes of β-Ga2O3 epitaxial layers grown on m- and c-oriented sapphire substrates by halide vapour phase epitaxy. The analysis of the experimental data was performed using Oliver-Pharr method. Theoretical values of Young.s modulus were calculated by density functional theory. The value of the Young's modulus of 234 GPa was measured for (100) β-Ga2O3 single crystals. The hardness and the Young's modulus for β-Ga2O3 epitaxial layers, were 12.5 GPa and 225 GPa for (-201) plane and 17 GPa and 300 GPa for (-311) plane, respectively.