Abstract. Carbonyl sulfide (COS), a trace gas showing striking similarity to CO2 in terms of biochemical diffusion pathway into leaves, has been recognized as a promising indicator of the plant gross primary production (GPP), the amount of carbon dioxide that is absorbed through photosynthesis by terrestrial ecosystems. However, large uncertainties about the other components of its atmospheric budget prevent us from directly relating the atmospheric COS measurements to GPP. The largest uncertainty comes from the closure of its atmospheric budget, with a source component missing. Here, we explore the benefit of assimilating both COS and CO2 measurements into the LMDz atmospheric transport model to obtain consistent information on GPP, plant respiration and COS budget. To this end, we develop an analytical inverse system that optimizes biospheric fluxes for the 15 plant functional types (PFTs) defined in the ORCHIDEE global land surface model. Plant uptake of COS is parameterized as a linear function of GPP and of the leaf relative uptake (LRU), which is the ratio of COS to CO2 deposition velocities in plants. A possible scenario for the period 2008–2019 leads to a global biospheric sink of 800 GgS yr−1, with higher absorption in the high latitudes and higher oceanic emissions between 400 and 600 GgS yr−1 most of which is located in the tropics. As for the CO2 budget, the inverse system increases GPP in the high latitudes by a few GtC yr−1 without modifying the respiration compared to the ORCHIDEE fluxes used as a prior. In contrast, in the tropics the system tends to weaken both respiration and GPP. The optimized components of the COS and CO2 budgets have been evaluated against independent measurements over North America, the Pacific Ocean, at three sites in Japan and at one site in France. Overall, the posterior COS concentrations are in better agreement with the COS retrievals at 250 hPa from the MIPAS satellite and with airborne measurements made over North America and the Pacific Ocean. The system seems to have rightly corrected the underestimated GPP over the high latitudes. However, the change in seasonality of GPP in the tropics disagrees with solar-induced fluorescence (SIF) data. The decline in biospheric sink in the Amazon driven by the inversion also disagrees with MIPAS COS retrievals at 250 hPa, highlighting the lack of observational constraints in this region. Moreover, the comparison with the surface measurements in Japan and France suggests misplaced sources in the prior anthropogenic inventory, emphasizing the need for an improved inventory to better partition oceanic and continental sources in Asia and Europe.