Computing with real Lie algebras: real forms, Cartan decompositions, and Cartan subalgebras. We describe algorithms for performing various tasks related to real simple Lie algebras. These algorithms form the basis of our software package CoReLG, written in the language of the computer algebra system GAP4. First, we describe how to efficiently construct real simple Lie algebras up to isomorphism. Second, we consider a real semisimple Lie algebra 𝔤. We provide an algorithm for constructing a maximally (non-)compact Cartan subalgebra of 𝔤; this is based on the theory of Cayley transforms. We also describe the construction of a Cartan decomposition 𝔤=𝔨⊕𝔭. Using these results, we provide an algorithm to construct all Cartan subalgebras of 𝔤 up to conjugacy; this is a constructive version of a classification theorem due to Sugiura.