> For AI agents: read the machine-readable documentation index at [https://corpuslaw.us/llms.txt](https://corpuslaw.us/llms.txt) or the single-file full reference at [https://corpuslaw.us/llms-full.txt](https://corpuslaw.us/llms-full.txt).

# 18 U.S.C. § 3585 — Calculation of a term of imprisonment

- **Citation**: 18 U.S.C. § 3585
- **Node Type**: section
- **Jurisdiction**: United States (federal)
- **Code Body**: United States Code (USC)
- **Official Source**: [https://uscode.house.gov/download/releasepoints/us/pl/119/95/xml_usc18@119-95.zip](https://uscode.house.gov/download/releasepoints/us/pl/119/95/xml_usc18@119-95.zip)
- **Canonical URL**: [https://corpuslaw.us/codes/federal/us-code/title-18/chapter-227/subchapter-d/section-3585](https://corpuslaw.us/codes/federal/us-code/title-18/chapter-227/subchapter-d/section-3585)
- **Semantic URL**: [https://corpuslaw.us/codes/federal/us-code/title-18/chapter-227/subchapter-d/section-3585](https://corpuslaw.us/codes/federal/us-code/title-18/chapter-227/subchapter-d/section-3585)

## Hierarchy

Title 18 — Crimes and Criminal Procedure > Chapter 227 > Subchapter D

## Text

(a) Commencement of Sentence.—A sentence to a term of imprisonment commences on the date the defendant is received in custody awaiting transportation to, or arrives voluntarily to commence service of sentence at, the official detention facility at which the sentence is to be served.

(b) Credit for Prior Custody.—A defendant shall be given credit toward the service of a term of imprisonment for any time he has spent in official detention prior to the date the sentence commences—(1) as a result of the offense for which the sentence was imposed; or (2) as a result of any other charge for which the defendant was arrested after the commission of the offense for which the sentence was imposed; that has not been credited against another sentence.
