2023 California Code › Penal Code - PEN › PART 3 - OF IMPRISONMENT AND THE DEATH PENALTY › TITLE 1 - IMPRISONMENT OF MALE PRISONERS IN STATE PRISONS › CHAPTER 4 - Treatment of Prisoners › ARTICLE 4 - Temporary Removal of Prisoners › Section 2690.5.

2690.5. (a) The superior court of the county in which a requesting district attorney or peace officer has jurisdiction may order the temporary removal of a prisoner from a state prison facility, and his or her transportation to a county or city jail, if a legitimate law enforcement purpose exists to move the prisoner. An order for the temporary removal of a prisoner may be issued, at the discretion of the court, upon a finding of good cause in an affidavit by the requesting district attorney or peace officer stating that the law enforcement purpose is legitimate and necessary. The order for the temporary removal of a prisoner to a county or city jail shall not exceed 30 days. Extensions of an order may be granted, but only upon application for an extension made in accordance with this section. The period of extension shall be no longer than the authorizing judge deems necessary to achieve the purposes for which it was granted, and shall not exceed an additional 30-day period beyond the initial period specified in the order for temporary removal.
(b) An order for the temporary removal of a prisoner shall include all of the following:
(1) A recitation of the purposes for which the prisoner is to be brought to the county or city jail.
(2) The affidavit of the requesting district attorney or peace officer stating that the law enforcement purpose is legitimate and necessary. The affidavit shall be supported by facts establishing good cause.
(3) The signature of the judge or magistrate making the order.
(4) The seal of the court, if any.
(c) Upon the request of a district attorney or peace officer for a court order for the temporary removal of a prisoner from a state prison facility pursuant to this section, the court may, for good cause, seal an order made pursuant to this section, unless a court determines that the failure to disclose the contents of the order would deny a fair trial to a charged defendant in a criminal proceeding.
(d) An order for the temporary removal of a prisoner shall be executed presumptively by the sheriff of the county in which the order is issued. It shall be the duty of the sheriff to bring the prisoner to the proper county or city jail, to safely retain the prisoner, and to return the prisoner to the state prison facility when he or she is no longer required for the stated law enforcement purpose. The prisoner shall be returned no later than 30 days after his or her removal from the state prison facility or no later than 30 days after the date of an order authorizing an extension pursuant to subdivision (a). The expense of executing the order shall be a proper charge against, and shall be paid by, the county in which the order is made. The presumption that the transfer will be effectuated by the sheriff of the county in which the transfer order is made may be overcome upon application of the investigating officer or prosecuting attorney stating the name of each peace officer who will conduct the transportation of the prisoner.
(e) If a prisoner is removed from a state prison facility pursuant to an order in accordance with this section, the prisoner shall remain at all times in the constructive custody of the warden of the state prison facility from which the prisoner was removed. During the temporary removal, the prisoner may be ordered to appear in other felony proceedings as a defendant or witness in the superior court of the county from which the original order for the temporary removal was issued. A copy of the written order directing the prisoner to appear before the superior court shall be forwarded by the district attorney to the warden of the prison having custody of the prisoner.
(f) The state is not liable for any claim of damage, or for the injury or death of any person, including a prisoner, that occurs during the period in which the prisoner is in the exclusive control of a local law enforcement agency pursuant to this section.
(Added by Stats. 2013, Ch. 56, Sec. 1. (SB 162) Effective January 1, 2014.)