Cost per lead can be calculated by dividing the total marketing expenses by the number of leads generated within a specific time period. The formula is: Total Marketing Expenses / Number of Leads Generated.