Preheat oven to 425°F and line a baking sheet with parchment paper.
For cubes: Peel the butternut squash, cut in half lengthwise, scoop out seeds, and cut flesh into 1-inch cubes. For halves: Cut squash in half lengthwise and scoop out seeds, leaving skin on.
For cubes: Toss squash cubes in a bowl with olive oil, salt, and pepper until evenly coated. Spread in a single layer on the prepared baking sheet.
For halves: Brush cut surfaces generously with olive oil and season with salt and pepper. Place cut-side down on the baking sheet.
Roast cubes for 25-30 minutes, flipping halfway through, until golden brown and tender with caramelized edges.
Roast halves for 40-50 minutes, cut-side down, until flesh is completely tender and deeply golden on the cut surface.
Remove from oven and let cool for 5 minutes before serving.