OPINION
CALLAHAN, Circuit Judge:This case arises out of a tragic incident. Kamal Lai (“Lai”), upset over a domestic disturbance with his wife, led police on a 45-minute high-speed chase on and off freeways before the officers were able to disable his vehicle. When Lai exited his truck he first tried to seriously hurt himself, then tried to provoke the officers into shooting him, and finally advanced on two officers holding a large rock over his head. When Lai refused to stop and continued to advance to within a few feet of the officers, the officers shot him. Lai’s widow, daughter, and estate (“Plaintiffs”) filed this action, asserting claims under 42 U.S.C. § 1983 and California law. The district court granted summary judgment for the defendants, finding that the officers were entitled to qualified immunity. We affirm the district court’s determinations that the officers thought that Lai posed an immediate threat of serious physical harm and that the officers’ beliefs were reasonable.
I
On March 6, 2005, the South San Francisco Police Department received a 911 telephone call from Lai’s wife reporting a domestic disturbance involving her husband, Lai. Lai interrupted the call, the *1114police called back, and after another disconnect, the police dispatcher managed to speak to Lai’s wife and overheard someone hitting her. While the dispatcher was still on the phone, Lai drove away in his grey Toyota pickup truck, and his wife gave the dispatcher the truck’s license plate number as well as Lai’s cell phone number.
Lai proceeded to the freeway where he entered southbound Highway 101. The California Highway Patrol (“CHP”) was notified and a high-speed chase ensued. For approximately 45 minutes, Lai traveled south and north on Highway 101, exiting the freeway to travel over city streets, and reentering the freeway. He did this at speeds ranging from 50 to over 100 miles an hour. At one point while on the freeway, Lai may have attempted to cause a motorcycle officer who was pursuing him to crash.
A police sergeant contacted Lai on his cell phone and told him to slow down because he would otherwise injure other people. Lai responded that he wanted to kill himself, and on a subsequent call, twice stated that he wanted to kill himself or have the police shoot him.
Meanwhile CHP Officer Frank Newman saw the pursuit heading toward his position and entered traffic to become the lead police vehicle. During the pursuit, Newman learned that Lai wanted officers to shoot him. The dispatcher also learned that Lai did not have any record of gun ownership and did not have any outstanding warrants.
Eventually Lai took an exit from the freeway onto a collector road where the CHP officers deployed a spike strip. Lai drove over the strip, partially disabling his vehicle, and managed to reenter the freeway and reach another off-ramp, where he lost control of his truck and veered off the ramp. The truck came to a stop in a ditch alongside the freeway. When Lai got out of his vehicle, numerous officers, including CHP Officer Otterby, yelled commands at him. Officer Newman addressed Lai through his patrol car loudspeaker and told him to put his hands in the air. Lai briefly complied, and then, putting his hands in his pockets, responded to Newman by saying “just shoot me, just shoot me.”
Lai then reached down to the ground and picked up a big rock that he smashed against his forehead three or four times, causing considerable bleeding. He next attempted to pull a four-foot long metal pole out of the ground and impale himself on it.
Lai started walking toward Officer Newman and CHP Officer Otterby, carrying a rock in his hand. When the officers told him to drop it, he pretended that his cell phone (which was also in his hand) was a pistol and pantomined pointing it at the officers. Officer Otterby recognized that the cell phone was not a gun and yelled to the officers not to shoot. Lai then threw several soft-ball sized rocks at Officers Newman and Otterby. The rocks missed the officers, but one shattered the spotlight on the patrol car.
During these events, Officer Newman requested assistance from any agency that could respond to the situation with less than lethal assistance, and was told that a K-9 unit was on its way.
Lai began walking toward the patrol cars while continuing to throw rocks. As he neared Officers Newman and Otterby, who were standing shoulder to shoulder, he held a large rock about the size of a football above his head. Lai failed to drop the rock when ordered by Officer Otterby to do so. Lai kept advancing at an irregular pace, forcing the officers to back up. Officer Otterby told Lai, “we are going to have to shoot you if you don’t drop that *1115rock.” Lai continued to advance, and when he was within a few feet of the officers, they simultaneously shot him. The eight shots killed Lai despite efforts to resuscitate him. Just over four minutes elapsed between the time Lai’s truck stopped moving and his shooting.
II
Plaintiffs filed this action in state court in December 2005 against California, the CHP, and Officers Newman and Otterby, asserting that Plaintiffs’ rights were violated when Lai was shot and killed. Plaintiffs asserted claims under 42 U.S.C. § 1983 for violations of the Fourth and Fourteenth Amendments and under California law for negligence, wrongful death, and assault and battery. In August 2006, the case was removed to the district court for the Northern District of California on the ground of federal question jurisdiction over the central claim that the officers had used excessive force in violation of the Fourteenth Amendment. After removal, Plaintiffs’ attorney failed to prosecute the case and the district court dismissed the case. New counsel filed a motion for relief from judgment pursuant to Federal Rule of Civil. Procedure 60(b). The motion was denied, Plaintiffs appealed to the Ninth Circuit, and the Ninth Circuit reversed and remanded. Lal v. State of California, 610 F.3d 518 (9th Cir.2010).
On remand, certain issues were dismissed, a second amended complaint relating to the state court claims was filed, the parties conducted discovery, and the defendants moved for summary judgment. On January 10, 2012, the district court granted the motion and dismissed the case. Plaintiffs filed a timely notice of appeal.
The district court offered the following explanation for its ruling:
[Tjaking the totality of circumstances into account, and viewing the undisputed evidence in the light most favorable to plaintiffs, the court finds that the officers acted reasonably. The evidence demonstrates: the officers were aware that officers were originally called to Lai’s home for a domestic violence report by Lai’s wife about him; Lai led police officers on a long and high speed chase over city streets as well as the freeway, during which Lai drove recklessly and in apparent disregard of others’ safety; Lai indicated he wanted to kill himself or have the officers shoot him; when Lai got out of his ear near the ditch at the off ramp, he did not comply with the officers’ instructions to put his hands up; Lai hit his own head with a rock until he bled and attempted to impale himself on a metal pole; Lai mimed using his cell phone as a gun that he pointed at the officers, which initially prompted Otterby, who recognized the phone was not a gun, to instruct all officers on the scene not to shoot; Lai picked up rocks and threw them at the officers’ car, breaking the light on the car; Lai came toward the officers with a football sized rock over his head, and ignored the officers’ instructions to put the rock down. Lai advanced with this rock to within a few feet of the officers; and both officers simultaneously shot Lai.... Based on these facts, the court concludes that defendants had probable cause to believe that they faced a threat of serious physical harm from Lai. As such their conduct in using deadly force was objectively reasonable.
Ill
We review “de novo a grant of summary judgment on the basis of qualified immunity,” and in “determining whether summary judgment is appropriate, [view] the evidence in the light most favorable to the non-moving party.” Gar*1116cia v. County of Merced, 639 F.3d 1206, 1208 (9th Cir.2011); see also Elder v. Holloway, 510 U.S. 510, 516, 114 S.Ct. 1019, 127 L.Ed.2d 344 (1994). In Smith v. City of Hemet, 394 F.3d 689, 701 (9th Cir.2005) (en banc), we reiterated:
The Supreme Court has said that “the ‘reasonableness’ inquiry in an excessive force case is an objective one: The-question is whether the officers’ actions are ‘objectively reasonable’ in light of the facts and circumstances confronting them[.]” [Graham v. Connor, 490 U.S. 386, 397,109 S.Ct. 1865,104 L.Ed.2d 443 (1989) ].... The question is not simply whether the force was necessary to ac: complish a legitimate police objective; it is whether the force used was reasonable in light of all the relevant circumstances.
(Internal quotation marks and citations omitted).
In Mattos v. Agarano, 661 F.3d 433 (9th Cir.2011) (en banc), we quoted the Supreme Court’s explanation that “[t]he doctrine of qualified immunity protects government officials ‘from liability for civil damages insofar as their conduct does not violate clearly established statutory or constitutional rights of which a reasonable person would have known.’ ” Id. at 440 (quoting Pearson v. Callahan, 555 U.S. 223, 231, 129 S.Ct. 808, 172 L.Ed.2d 565 (2009)). We further explained that qualified immunity shields an officer from liability even if his or her action resulted from “a mistake of law, a mistake of fact, or a mistake based on mixed questions of law and fact,” and that the “purpose of qualified immunity is to strike a balance between the competing need to hold public officials accountable when they exercise power irresponsibly and the need to shield officials from harassment, distraction, and liability when they perform their duties reasonably.” Id. (internal quotation marks and citations omitted). In Messerschmidt v. Millender, — U.S. -, 132 S.Ct. 1235, 1244, 182 L.Ed.2d 47 (2012), the Supreme Court reiterated that “[qualified immunity gives government officials breathing room to make reasonable but mistaken judgments, and protects all but the plainly incompetent or those who knowingly violate the law.” (Internal quotation marks and citations omitted). Furthermore, because “qualified immunity is ‘an immunity from suit rather than a mere defense to liability ... it is effectively lost if a case is erroneously permitted to go to trial.’ ” Pearson, 555 U.S. at 231, 129 S.Ct. 808 (quoting Mitchell v. Forsyth, 472 U.S. 511, 526, 105 S.Ct. 2806, 86 L.Ed.2d 411 (1985)).
In determining whether an officer is entitled to qualified immunity, we consider (1) whether there has been a violation of a constitutional right; and (2) whether that right was clearly established at the time of the officer’s alleged misconduct. Pearson, 555 U.S. at 232, 129 S.Ct. 808. Courts are “permitted to exercise their sound discretion in deciding which of the two prongs of the qualified immunity analysis should be addressed first in light of the circumstances in the particular case at hand.” Id. at 236,129 S.Ct. 808.
The measuring rod for determining whether an official’s conduct violates a plaintiffs constitutional right was set forth by the Supreme Court in Ashcroft v. al-Kidd, — U.S.-, 131 S.Ct. 2074, 2083, 179 L.Ed.2d 1149 (2011):
A Government official’s conduct violates clearly established law when, at the time of the challenged conduct, “[t]he contours of [a] right [are] sufficiently clear” that every “reasonable official would have understood that what he is doing violates that right.” Anderson v. Creighton, 483 U.S. 635, 640, 107 S.Ct. 3034, 97 L.Ed.2d 523 (1987).
*1117The Supreme Court provided further guidance in Graham v. Connor, 490 U.S. 386, 109 S.Ct. 1865, 104 L.Ed.2d 443 (1989). We have held that Graham directs courts to first consider the nature and quality of the alleged intrusion and to then “consider the governmental interests at stake by looking at (1) how severe the crime at issue is, (2) whether the suspect posed an immediate threat to the safety of the officers or others, and (3) whether the suspect was actively resisting arrest or attempting to evade arrest by flight.” Mottos, 661 F.3d at 441. Of these, the most important is whether the suspect posed an immediate threat to the safety of the officers or others. Id. (citing City of Hemet, 394 F.3d at 702).
This is the crux of the appeal. The district court found both that Lai posed an immediate threat to the safety of the officers, and that, even if he did not, a reasonable officer could have thought he did. Both conclusions are sound.
Plaintiffs admit that Lai was holding a football-sized rock over his head when he continued to advance toward Officers Newman and Otterby, who shot him when he was about a yard away. In light of Lai’s prior actions — the high speed chase, hitting himself with a stone, throwing rocks at the officers — the officers reasonably believed that Lai would heave the rock at them. Indeed, Plaintiffs do not really argue otherwise.
Instead, they argue that the officers should have retreated or that they somehow should have defused the situation before Lai started advancing. These contentions are not factually or legally persuasive. The confrontation was in a ditch alongside a freeway, and the officers could hardly allow Lai to proceed on foot onto the freeway. Nor could they have allowed Lai to remain in his truck and reenter the freeway, for Lai’s wish to commit suicide would have endangered the lives of others, as well as his own. Indeed, the officers were exploring alternate methods of dealing with Lai, attempting to continue the engagement with Lai until the K-9 unit arrived. But Lai forced the issue by advancing on the officers. By the time that Lai, contrary to the officer’s commands, advanced to within seven or eight feet of the officers, thereby creating a reasonable fear of imminent serious physical harm, spraying Lai with pepper spray would not have stopped Lai from hurling the rock at the officers. The fact that Lai was intent on “suicide by cop” did not mean that the officers had to endanger their own lives by allowing Lai to continue in his dangerous course of conduct.
Plaintiffs’ experts, however, argue that the situation should not have come to this point. They contend that the officers should have seized Lai earlier, should have used pepper spray, and should have waited for less than lethal devices to arrive. They criticize the officers for containing Lai in a small area, not waiting, and not retreating. Clearly, when Lai advanced on the officers with a large rock held over his head, the officers sincerely and reasonably believed that Lai intended to seriously harm them if they did not shoot him.
The cases cited by Plaintiffs are not to the contrary. In A.D. v. California Highway Patrol, 712 F.3d 446 (9th Cir.2013), the court affirmed the denial of qualified immunity to an officer who had emptied his gun shooting a person who had rammed her car into the police patrol cars after she was cornered following a high speed chase. The court found that a reasonable jury could find that the officer had “used deadly force with a purpose to harm [the deceased] unrelated to a legitimate law enforcement objective.” Id. at 451. In Glenn v. Washington County, 673 F.3d *1118864 (9th Cir.2011), the Ninth Circuit vacated a grant of summary judgment where the police officers used a beanbag shotgun on a person armed with a knife, who was not threatening the police or others when he was shot. Id. at 873-74. Unlike those cases, here, Lai was threatening the officers with immediate serious harm.
Plaintiffs, however, argue that under the totality of the circumstances, the jury should be allowed to determine whether the officers were unreasonable in not deescalating the situation before Lai advanced on the officers with a rock over his head. Citing Billington v. Smith, 292 F.3d 1177 (9th Cir.2002), Plaintiffs argue that where an officer intentionally or recklessly provokes a violent confrontation, he may be held liable for his otherwise defensive use of deadly force. A careful reading of Billington weighs against Plaintiffs’ perspective in this case. We explained:
In Scott v. Henrich [39 F.3d 912 (9th Cir.1994) ], we held that even though the officers might have had “less intrusive alternatives available to them,” and perhaps under departmental guidelines should have “developed a tactical plan” instead of attempting an immediate seizure, police officers “need not avail themselves of the least intrusive means of responding” and need only act “within that range of conduct we identify as reasonable.” We reinforced this point in Reynolds v. County of San Diego, [84 F.3d 1162 (9th Cir.1996) ] which distinguished Alexander [v. City and County of San Francisco, 29 F.3d 1355 (9th Cir.1994) ] because “the court must allow for the fact that officers are forced to make split second decisions.” We affirmed summary judgment for the defendant police officers despite experts’ reports stating — like the expert report in the case at bar — that the officers should have called and waited for backup, rather than taking immediate action that led to deadly combat. We held that, even for summary judgment purposes, “the fact that an expert disagrees with the officer’s actions does not render the officer’s actions unreasonable.” Together, Scott and Reynolds prevent a plaintiff from avoiding summary judgment by simply producing an expert’s report that an officer’s conduct leading up to a deadly confrontation was imprudent, inappropriate, or even reckless. Rather, the court must decide as a matter of law “whether a reasonable officer could have believed that his conduct was justified.”
Billington, 292 F.3d at 1188-89 (footnotes omitted).
In the case at bar, there is no suggestion that the officers intentionally provoked Lai. Rather, the totality of the circumstances shows that they were patient. They allowed Lai to lead them on a 45-minute high-speed chase, during which they tried to talk him into surrendering, and when he got out of the truck, they were willing to give him time to cool off. Instead, it was Lai who forced the confrontation. Thus, even assuming that it might have been possible for the officers to have given Lai a wider berth, under our opinion in Billington, there is no requirement that such an alternative be explored. A police officer’s immunity does not become less if his assailant is motivated to commit “suicide by cop.”
IV
This lawsuit arose out of a tragic event. Lai was so upset after an argument with his wife that he led the police on a high speed chase for 45 minutes before the officers were able to disable his pickup truck. In the four minutes that elapsed after Lai exited the truck, he first tried to seriously injure himself, tried to provoke the officers into shooting him by pantomin-ing shooting at them with his cell phone, *1119threw rocks at the officers, and then, ignoring directions to stop, advanced upon two officers threatening them with a large rock he held over his head. At that moment, the only alternative force then available to the officers, pepper spray, would not have alleviated the danger of Lai hurling the rock at the officers. Moreover, there was no reason for the officers to believe that Lai would act rationally. Under the totality of the circumstances, the district court’s determinations that the officers objectively feared immediate serious physical harm and that a reasonable officer could have believed that Lai threatened him with immediate serious danger are sound. That Lai may have been intent on committing “suicide by cop” does not negate the fact that he threatened the officers with such immediate serious harm that shooting him was a reasonable response. The district court’s grant of summary judgment is AFFIRMED.