Sometimes adding an app in SharePoint 2013 does not work. It throws an error "Sorry,something went wrong". This can happen due to a lot of reasons. But when i ran through this problem it was because of using a custom master page.
My custom master page did not have a "Breadcrumb" content placeholder (PlaceHolderTitleBreadcrumb) But "adding apps" expected that content placeholder. So after adding it the problem was resolved.
Make sure you have all placeholders as below:
1. DeltaPlaceHolderLeftNavBar
2. PlaceHolderLeftNavBar
3. DeltaPlaceHolderPageTitleInTitleArea
4. PlaceHolderPageTitleInTitleArea
Also each of them should not be set to Visible=False.
The code for the content placeholders are:
My custom master page did not have a "Breadcrumb" content placeholder (PlaceHolderTitleBreadcrumb) But "adding apps" expected that content placeholder. So after adding it the problem was resolved.
Make sure you have all placeholders as below:
1. DeltaPlaceHolderLeftNavBar
2. PlaceHolderLeftNavBar
3. DeltaPlaceHolderPageTitleInTitleArea
4. PlaceHolderPageTitleInTitleArea
Also each of them should not be set to Visible=False.
The code for the content placeholders are:
<SharePoint:AjaxDelta id="DeltaPlaceHolderLeftNavBar" BlockElement="true" runat="server">
<asp:ContentPlaceHolder id="PlaceHolderLeftNavBar" runat="server">
</asp:ContentPlaceHolder>
</SharePoint:AjaxDelta
<SharePoint:AjaxDelta id="DeltaPlaceHolderPageTitleInTitleArea" runat="server">
<asp:ContentPlaceHolder id="PlaceHolderPageTitleInTitleArea" runat="server">
</asp:ContentPlaceHolder><asp:ContentPlaceHolder id="PlaceHolderTitleBreadcrumb" runat="server" Visible="false"></asp:ContentPlaceHolder>
</SharePoint:AjaxDelta>



