 <p>you need both <code>hidden.bs.collapse</code> and <code>shown.bs.collapse</code></p> <pre><code>$(document).ready(function() { function toggleChevron(e) { $(e.target) .prev('.panel-heading') .find("i") .toggleClass('fa-question fa-angle-up'); } $('#accordion').on('hidden.bs.collapse shown.bs.collapse', toggleChevron); }); </code></pre> <p><a href="https://jsfiddle.net/BG101/pmadwvpk/8/" rel="nofollow"><strong>FIDDLE</strong></a></p>