@4565montrose,
It can be considered selfish to tell your husband out of guilt. If you truly feel remorse for what you have done, you should learn from your mistake and resolve in your heart you will never do it again. I've made the mistake myself, you can use this to make your relationship stronger. You can be stronger too with how you deal with this.