BEWARE OF BONUSES AFFECTING OVERTIME CALCULATIONS
Overtime is paid at the employee’s “regular rate of pay”. Some new court decisions and subsequent interpretations have also provided that nondiscretionary production bonuses, must be included in an employee’s “regular rate of pay” before figuring overtime payments.
The definition of an nondiscretionary production bonus is: The employer predetermines the specific criteria that is required to receive a bonus. Employees expect to earn the bonus if they meet the criteria. An employer’s incentive pay plan that provides additional compensation for exceeding performance or productivity goals is an example of how nondiscretionary bonuses are executed in the workplace.
To calculate overtime for an employee with this bonus program, you must allocate the bonus dollars over the time period the employee earned the bonus (week, month, year, etc.) The courts explained it this way:
 Take the bonus earned during the bonus period;
 Divide the bonus by the total number of hours worked during the bonus period;
 Multiply the resulting number by 0.5; and
 Multiply the resulting number by the total number of overtime hours worked during the bonus period.
You must then show this amount on the wage statement (payroll stub) for the pay period that the bonus is paid.
Here is a hypothetical offered by the court:
The hypothetical employee earned a $360 monthly bonus for work performed during the previous month of December, from December 1 to December 31, 2017. This bonus would be reflected on the January 7 to January 20, 2018 wage statement. To calculate the OverTimePayOverride line, the hours worked in December 2017 would be used because that is the time period in which the bonus was earned. In this hypothetical, the employee had worked 160 regular hours and 20 overtime hours in December 2017, for a total of 180 hours. First, divide $360 by 180, which results in $2. This number represents the increase to the regular hourly rate. Multiply $2 by 0.5 and the result, $1, represents the increase to the overtime hourly rate. Then, take $1 and multiply it by 20, the overtime hours worked during December 2017, and the result, $20, is the overtime pay adjustment, which would be identified as the OverTimePayOverride line on the wage statement.
This is not the calculation you would use for a flatrate bonus. The court said that the flatrate bonus should be calculated as: A flat sum bonus is “factored into an employee’s regular rate of pay by dividing the amount of the bonus by the total number of nonovertime hours actually worked during the relevant pay period and using 1.5, not 0.5, as the multiplier for determining the employee’s overtime pay rate.”
This reasons that a bonus would be further diluted if you include all hours including overtime hours in the calculation.
California has more information about how to calculate overtime for different situations. Here are a few common questions but you can find more at https://www.dir.ca.gov/dlse/FAQ_Overtime.htm
3.  Q.  Is a bonus included in the regular rate of pay for purposes of calculating overtime?

A.  Yes, if it is a nondiscretionary bonus. A nondiscretionary bonus is included in determining the regular rate of pay for computing overtime when it is based upon hours worked, production or proficiency or as an incentive to remain employed by the same employer. Incentive bonuses include flat sum bonuses. Flat sum bonuses must be computed by dividing the bonus by the maximum legal regular hours worked, not by the total hours worked during the pay period. Bonuses designed as an incentive for increased production for each hour worked are divided by the total hours worked in the pay period. Discretionary bonuses or sums paid as gifts at a holiday or other special occasions, such as a reward for good service, which are not measured by or dependent upon hours worked, production or efficiency, are not included for purposes of determining the regular rate of pay.  
4.  Q.  Are any amounts excluded from the regular rate of pay? 
A.  Yes, there are certain types of payments that are excluded from the regular rate of pay. Examples of some of the more common exclusions are sums paid as gifts for special occasions, expense reimbursements, payments made for occasional periods when no work is performed due to vacation, holiday, illness, failure of the employer to provide sufficient work, premium pay for Saturday, Sunday, or holiday work, and discretionary bonuses.  
5.  Q.  Are salaried employees entitled to overtime? 
A.  It depends. A salaried employee must be paid overtime unless they meet the test for exempt status as defined by federal and state laws, or unless they are specifically exempted from overtime by the provisions of one of the Industrial Welfare Commission Wage Orders regulating wages, hours and working conditions.  
6.  Q.  How is overtime calculated if I work at different rates of pay in the same workweek? 
A.  If you are paid two or more rates by the same employer during the workweek, the regular rate is the “weighted average” which is determined by dividing your total earnings for the workweek, including earnings during overtime hours, by the total hours worked during the workweek, including the overtime hours. For example, if you work 32 hours at $11.00 an hour and 10 hours during the same workweek at $9.00 an hour, the weighted average (and thus the regular rate for that workweek) is $10.52. This is calculated by adding your $442 straight time pay for the workweek [(32hours x $11.00/hour) + (10 hours x $9.00/hour) = $442] and dividing it by the 42 hours you worked. 