You can also access this tutorial in German and French.


The message "You do not have the roles required to access this portlet" is shown in a red frame when a Liferay portlet is hidden from a user by retracting the view permission. In this video we show how to remove this message and hide the portlet completely.


Did you ever try to hide a Liferay portlet and got the message "You do not have the roles required to access this portlet"? I'll show you how to get rid of this. Hi, my name is Andreas Hense and I make videos on business process automation. When you hide a portlet in Liferay it doesn't just become invisible for the user you want to hide it from. Liferay tells the user “Hey, there's something here but it's hidden from you!" For my use case this wasn't the right behavior. I had some trouble finding out how to change this. So let me save you time. Let me first show you what the problem is. Here, we have two browser windows open with the Liferay portal and in the smaller one on the right hand side - um - if we go down we can see that there is some text saying "Next meeting for instructors in two weeks" and this is a text that is in a web content display and the rights are set in a way that only the instructor role can read or view this this portlet and we are currently logged in with the user having this role. If we go to the larger window we are currently not logged in and if we scroll down, we see a red message "You do not have the roles required to access this portlet". What we want to do is that we want to completely hide the existence of this portlet from the users who do not have the right to see it. So how can we do that? Let's first look at how this has been set up. So, if we go in as a administrator and we go here to the editing part of this and we select this web content display here we have the permissions and in the permissions you can see that apart from the owner who has all the rights the instructor has viewing rights and no one else so that's how it was configured and the solution to this is very simple. All we have to do is add a line to a file called and the file is either already in the top folder of your Liferay installation or you need to create one. Did you find another way of solving the problem? Let me know in the comments!