Can I tell my friend that they're boring?
That sounds mean. Why do you think they're boring?
Because they are, not that it matters
All of our friends have different qualities that make them unique, but not all friends will be interesting conversationalists. If your friend is boring from time to time, it's your job as their friend to hear them out and not be critical of them. If you tell your friend they're boring, they're likely to feel hurt and embarrassed.
It's not my responsibility. They can't be boring all the time.
You are right it is not your responsibility to make them be more interesting but it is to be kind to our friends. It would make you a bad friend to be mean to them.