How can I make certain app or page in my package automatically available for System Administrators after package installment?

I mean, for example, I have created a package with one application and two pages. How can I make this app automatically be added to System Administrators app list so it would appear in drop down menu and also at least one of the page would be visible to the user?

Currently no user can access my app or any of my pages until he or she configures them to be visible and on in their profile or user settings. I would like this to happen automatically.

Does anyone know the answer to this question?

2 Answers 2


This is a really subtle shortcoming of Permission Sets and Profiles. Go and vote on the idea now!

Assigned apps and tab settings can't be packaged as permission set components

If you truly need to automate this, it's not impossible. You could stage up a page with the correct checkboxes selected with some URL hacking and send that back to the user like the following example:

InstallAppController.cls (use API 31.0 or app returns 0DS prefixed object instead of 02u)

public with sharing class InstallAppController {

    public PageReference doSaveAppVisibility() {
        //find app by name
        AppMenuItem appMenuItem = [SELECT Id FROM AppMenuItem WHERE Name = 'Widgets'];

        //choose profile by name
        Profile profile = [SELECT Id FROM Profile WHERE Name = 'System Administrator'];
        String profileId = String.valueOf(profile.Id).left(15);

        //request app to be visible on this profile
        PageReference save = new ApexPages.StandardController(appMenuItem).edit();
        save.getParameters().put('selected_in_profile', profileId);

        //take user to save page
        return save;



<apex:page controller="InstallAppController" action="{!doSaveAppVisibility}">
    <apex:pageMessages showDetail="true" />

The above is fragile and unsupported; one should never ever do it - the problem is more fundamental: packaged Permission Sets lose app and tab visibility, and you're stuck with profiles.

enter image description here


Assuming that you have created and packaged said app (i.e. created an Application and packaged that, i.e. from Setup->Create->Apps), you should have the option at install time to install it for a given set of users:

enter image description here

It should then automatically appear on the profile that you installed it for.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .