We introduce CosmoBit, a module within the open-source GAMBIT software framework for exploring connections between cosmology and particle physics with joint global fits. CosmoBit provides a flexible framework for studying various scenarios beyond ΛCDM, such as models of inflation, modifications of the effective number of relativistic degrees of freedom, exotic energy injection from annihilating or decaying dark matter, and variations of the properties of elementary particles such as neutrino masses and the lifetime of the neutron. Many observables and likelihoods in CosmoBit are computed via interfaces to AlterBBN, CLASS, DarkAges, MontePython, MultiModeCode, and plc. This makes it possible to apply a wide range of constraints from large-scale structure, Type Ia supernovae, Big Bang Nucleosynthesis and the cosmic microwave background. Parameter scans can be performed using the many different statistical sampling algorithms available within the GAMBIT framework, and results can be combined with calculations from other GAMBIT modules focused on particle physics and dark matter. We include extensive validation plots and a first application to scenarios with non-standard relativistic degrees of freedom and neutrino temperature, showing that the corresponding constraint on the sum of neutrino masses is much weaker than in the standard scenario.