How can I clear the history for only one tab?


$ionicViewService.clearHistory() clears the history for all tabs, how would I go about clearing it only for a single tab?

The use case is that I have 3 tabs, within one of the tabs I have the “user manual,” which can be accessed by a link on every page. When a user switches back to the tab with the user manual, they will see the most recently viewed help page. I would like to take them back to base page on that tab.


+1 bump, i would like to know how to do this also.


Another +1 for this.

Since parallel histories are maintained for tabs, we should be able to clear a single tab history.

Another use case for this is a shopping app, where one tab is for browsing and another tab has the shopping cart. You probably will need to clear the cart history after payment but you may want to keep the browsing history alive.

Any ideas how to achieve this? (thanks in advance)


Try this

<ion-tab ng-click="loadRootView('tabrootstate')"></ion-tab>

$scope.loadRootView = function(state) {
      $state.go(state, {}, {
        reload: true,
        inherit: false,
        notify: true

This absolutely did it for me. Thanks.


Thanks! Work like a charm!