Clean and wash the Swiss chard. Separate the leaves from the stems and cut into fine strips. Cut the stems into small pieces. Peel the onion and cut into fine rings. Peel the garlic and cut into thin slices. Core and finely chop the chilli pepper.
Drain the butter in a saucepan, sauté the onions, garlic and chard stalks over a low heat for 2 - 3 minutes. Add the chard and let it collapse. Stir in the cream and chilli and let everything simmer for 3 - 4 minutes. Finely crumble the feta and stir into the vegetables. Season to taste with salt.
Cook the spaghetti in salted water until al dente. Drain and fold in the chard and feta cream.