This study investigates the lifetime costs associated with concrete barriers and steel guardrails. We introduce a cost analysis methodology that incorporates critical factors such as construction costs, maintenance costs, exposure risks during maintenance activities, and the costs imposed to traveling public through the increased traffic and the crash outcomes. We integrate various parameters including economic factors, road geometry, general weather condition, and traffic mix to estimate a location-dependent cost for each type of barrier accurately. A software tool, named CalBarrier, was developed during this study to carry out the calculations and the comparison of lifetime cost of aforementioned barriers. An inherent strength of this research is its reliance on recent real data extracted from various databases of California Department of Transportation (Caltrans), ensuring precision and relevance in accounting for various influential factors. Drawing insights from Caltrans practices and interviews with their personnel, this study emphasizes the intricate decision-making process involved in mitigating safety risks and reducing operational expenses. Although our data originates from California, the methodology for life cycle cost analysis, and our software are applicable for regions with different socio-economic conditions by adjusting the baseline costs, making our findings a valuable resource for other areas facing comparable challenges.