Home  >  Blog  >   Tableau

How to embed tableau reports securely on the web?

Rating: 4
  1. Share:
Tableau Articles

Embedding Tableau Reports Securely on the Web

The need for tableau reports on the web:

Tableau lets people across your organization to communicate and understand the data in a whole new interactive way, at the same time continuing with the existing license and security framework available to you.

Why embed a Tableau dashboard:

A good organizations’ dashboard makes its users understand the information within a glance. It allows even non-technical users to create interactive and real-time visualizations within minutes. Furthermore, it may also have advantages to grasp the existing security options of the defined web portal.

Interactive users
Many people might not be comfortable in reporting and making correct decisions while accessing the information on a particular website. They might get drifted easily which in turn makes their whole work look less efficient.

Whereas embedding tableau in a particular web portal makes it even more interesting and appealing to the users wanting them to access more data and information for their needs

When your reports are based on on-demand software:

When offering service to the clients you need to control the overall branding of the product as well as dashboard. Instead of redirecting the users from the actual product to the third party solution i.e tableau server and making them resent, you can embed the tableau report directly into your particular product. The ultimate result is the seamless blend of the underlying technology (which users are unaware of) and the branding of the commodity, as a result of making the whole process more user-friendly.

Enhance your IT skills and proficiency by taking up the Tableau Training.

Methods to embed a dashboard:

Embedding dashboard can be achieved by using any of the below methods:

  • Using tableau Javascript
  • Using dashboard’s URLs in an iframe or image tag
  • Writing one’s own code using tableau’s Javascript API

Regardless of any of the above methods you choose to use, you can control the complete embedded view with the help of equally important ‘passed parameters’. We shall now explore in detail all the above three methods as well as subsequent parameters.

MindMajix Youtube Channel

Using tableau Javascript:

This is the simplest and easiest as well as preferred approach of all, here we can embed a dashboard into another web page by using Javascript code available by tableau in its share button. You can select the width and height of the dashboard as well as the ability to turn on/off the toolbar and tabs thus providing a technique to quickly embed dashboards into another web page. Let us have a quick look at the below example:

You can notice that tags are used to specify or enter certain values. Additionally, tags can also be used to pass parameters such as an initial filter. Below is an example:

As we can see the entry will initially filter the embedded view by restricting to a particular dimension region such as west. The name and site root parameters are the most required parameters while embedding a view under this method.

Using an iframe or image tag

Another approach to embedding the above view is by using an iframe. The embed URL parameter is most required. However, occasionally you can use parameters that control the toolbar and tab options. Additionally, you can add filters to the URL to make it more appealing to the viewers when loaded. The tableau is restricted to the west region dimension and also specifies a certain date.

Writing your own JavaScript API:

The tableau Javascript API(JS API) lets you incorporate tableau visuals into web applications. It allows customer interactions and enables a deep level of control and combines the functionality. For example, you can code a single control that filters a group of locations and select specific locations in them and make the data available for the users to download. Let us know a few more things that can be done using JS API

  • Display visualizations from Tableau Server, Tableau Public, and Tableau online into the web pages
  • To load and resize visualizations effectively
  • Chose marks in visualizations
  • Export visualizations to image or pdf file
  • Filter the data for visualizations with the help of HTML
  • Reacting to the events in visualizations.
  • Additional control using passed parameters

Whether you adopt any of the above methods, you can further pass additional parameters to the complete view.                               

Tips and Tricks to follow while embedding a dashboard
Let us have a quick glance at some of the tips and tricks to be followed while embedding the dashboard using TABLEAU.

Read these latest Tableau Interview Questions that helps you grab the high-paying job

Filter formats:

  • Dimensions: While passing dimension filters, just list each value by separating them with a comma. If you want to pass multiple dimension filters separate them with an ampersand. For example,
  • Field1=value 1, value 2, value3 & field2=value1, value2
  • Measures: Measures can be filtered the same as the above method by passing distinct values. However, tableau does not support using greater than or less than logic.
  • Date/Time: To filter the date or time field, the time component can be regarded as optional. For instance,

Date field=yyyy-mm-dd     hh:mm:ss (optional)

Character Limits:

Although there is no limit on the number of parameter values to pass on an embedded view, there might be a URL length restriction imposed by the end user’s browser.

HTTP Protocol does not impose any limit on URL length as you can notice many modern-day browsers can handle URL length up to 80,000 characters, however internet explorer 8 & 9 have a maximum character limit of 2,083 characters only.

Therefore, you should be conscious of keeping URL’s under this limit to assure compatibility. Note that the complete URL length does not mean to definitely include passed parameters and resulting values from it.

Related Article: Embedded Software Engineer Interview Questions

Use of trusted ticket authentication:

When an embedded view is being accessed, the authentication mode available on the tableau server is used to know the user’s identity. To explain, if your server is constructed for local user authentication, then users must log in through a form provided by the embedded view. This may be a tiresome process for the user if he had already authenticated into the web application.

To overcome this situation tableau server gives an option of the single sign-on method where an already authenticated user needs not log in further into an embedded tableau view. He would be in your active directory and SSPI and would be treated as a ‘licensed tableau server user’. However, in all the other situations, the trusted ticket authentication method is used as an alternative to a single sign-on method.

While using a trusted ticket authentication method, the web server takes all the responsibility of the authenticated users. Much before embedding the view, the web server does two POST parameters to the tableau server:

  • Username
  • Client_ip

The web server receives unique_id through the form which is further used in the embedded view’s URL, as shown:


If you are using javascript, the tag can be used as:


Once if unique_id is issued, it must be reclaimed within 15 seconds from a machine matching the client_ip specified, or else it would become invalid. As soon as the tableau server receives the request that the user has logged in, then a trusted ticket URL is resolved to that of a standard request.

Even before a web server can make a request for trusted ticket authentication, it must first be on the ‘trusted list’ of the tableau server. This can be achieved using tabadmin command where xxx.xxx.xxx.xxx indicates an IP address for every trusted web server.
Tabadmin set wgserver.trusted_hosts “xxx.xxx.xxx.xxx , xxx.xxx.xxx.xxx”.

Learn Tableau Server Tutorial

List Of Tableau Courses:

 Tableau Advanced
 Tableau Server
 Data Visualization and Dashboarding Fundamentals


Join our newsletter

Stay updated with our newsletter, packed with Tutorials, Interview Questions, How-to's, Tips & Tricks, Latest Trends & Updates, and more ➤ Straight to your inbox!

Course Schedule
Tableau TrainingMay 21 to Jun 05View Details
Tableau TrainingMay 25 to Jun 09View Details
Tableau TrainingMay 28 to Jun 12View Details
Tableau TrainingJun 01 to Jun 16View Details
Last updated: 03 Apr 2023
About Author

As a Senior Writer for Mindmajix, Saikumar has a great understanding of today’s data-driven environment, which includes key aspects such as Business Intelligence and data management. He manages the task of creating great content in the areas of Programming, Microsoft Power BI, Tableau, Oracle BI, Cognos, and Alteryx. Connect with him on LinkedIn and Twitter.

read more
Recommended Courses

1 / 15