Pre-heat the oven to 390F (200C).
Put the butternut squash, sweet potatoes, red onions and pesto in an oven safe tray and toss it.
Sprinkle salt and pepper over, and place the tray in the oven at middle tier.
Roast for 20-30 minutes until the pieces has softened.
Meanwhile, roast the pine nuts in a hot, dry, frying pan until they take on some color.
Sprinkle the pine nuts over the roasted butternut squash and sweet potatoes before serving.