Developing Applications Q&A

This topic provides answers to common questions related to developing Samsung Smart TV applications.

Application Installation

The following questions are related to installing and uninstalling applications.

Application Testing

The following questions are related to testing applications.

Data and File Handling

The following questions are related to handling data and files on the TV.

Device Information and Firmware

The following questions are related to accessing device information and managing device firmware.

  • A

    On a Samsung Smart TV, you can find the DUID by selecting "Menu > Support > Contact Samsung".

    To retrieve the DUID from within your application, use the getDuid() method of the ProductInfo API.

    #duid #device id #productinfo api

  • A

    You can retrieve the TV language setting through the JavaScript navigator.language property.

    #tv setting

  • A

    The user agent string for Samsung TVs depends on the TV model year.

    Table 1. User agent strings for Samsung TVs
    Product User Agent
    2017 models Mozilla/5.0 (SMART-TV; LINUX; Tizen 3.0) AppleWebKit/538.1 (KHTML, like Gecko) Version/3.0 TV Safari/538.1
    2016 models Mozilla/5.0 (SMART-TV; Linux; Tizen 2.4.0) AppleWebKit/538.1 (KHTML, like Gecko) Version/2.4.0 TV Safari/538.1
    2015 models Mozilla/5.0 (SMART-TV; Linux; Tizen 2.3) AppleWebkit/538.1 (KHTML, like Gecko) SamsungBrowser/1.0 TV Safari/538.1
    2014 models Mozilla/5.0 (SMART-TV; X11; Linux armv7l) AppleWebkit/537.42 (KHTML, like Gecko) Safari/537.42
    2013 models Mozilla/5.0 (SMART-TV;X11; Linux i686) AppleWebkit/535.20+ (KHTML, like Gecko) Version/5.0 Safari/535.20+
    2012 models Mozilla/5.0 (SMART-TV; X11; Linux i686) AppleWebKit/534.7 (KHTML, like Gecko) Version/5.0 Safari/534.7
    2011 models Mozilla/5.0 (SmartHub; SMART-TV; U; Linux/SmartTV) AppleWebKit/531.2 (KHTML, like Gecko) Web Browser/1.0 SmartTV Safari/531.2+

    For more information, see Retrieving Platform Information.

    #user agent

  • A

    To find the model code on the TV, in the Smart Hub, select "Settings > Support > About This TV". The model code is a string that specifies various TV characteristics.

    The following table shows the information contained in the model code, and its sequence:

    Table 1. Model code information
    Screen Technology Region Screen Size Model Year Screen Matrix Series and Model
    "H" (DLP)
    "K" (OLED)
    "L" (LCD)
    "P" (Plasma)
    "Q" (QLED)
    "U" (LED)
    "A" (Asia)
    "E" (Europe)
    "N" (North America)
    Size in inches "E" (2012)
    "F" (2013)
    "H" (2014)
    "J" (2015)
    "K" (2016)
    "L" (2017)
    "M" (2018)
    None (FHD)
    "P" (Plasma)
    "Q" (QLED)
    "S" (SUHD)
    "U" (UHD)
    Series and model number

    For example, the "UN40MU9000" model code defines a TV with the following characteristics:

    • LED screen
    • North America region
    • 40-inch screen
    • 2018 model year
    • UHD screen matrix
    • Series 9 model

    #model code

  • A

    To retrieve the MAC address of a Smart TV, use the getPropertyValue() method of the SystemInfo API with the applicable network adapter property:

    • For the Ethernet network adapter, use the ETHERNET_NETWORK property.
    • For the Wi-Fi network adapter, use the WIFI_NETWORK property.

    #ethernet #wifi #network adapter #mac address #systeminfo api

  • A

    To retrive the Smart Hub country code, use the getSystemConfig() method of the ProductInfo API with the CONFIG_KEY_SERVICE_COUNTRY key.

    #smart hub #country code #productinfo api

  • A

    To download the latest TV firmware, on the Samsung Web site, find your TV model. On the TV model page, select "User manual & Downloads". The "Upgrade File" contains the latest TV firmware.

    #firmware upgrade #tv model

  • A

    No, forcing firmware updates is not supported.

    #firmware update
    #force update

  • A

    No. For security reasons, downgrading the TV firmware is not supported.

    #firmware downgrade

  • A

    Since 2016 models, to reset the TV to original factory settings, in the Smart Hub, select "Settings > Self Diagnosis > Reset". The reset changes the DUID.


    The "Settings > Self Diagnosis > Reset Smart Hub" feature removes all Smart Hub and logged-in Samsung Account data from the TV. It does not change the DUID.

    #duid #reset smart hub #factory settings
    #factory reset #original settings

  • A

    It is not possible to detect when the user has clicked the TV power key. However, you can implement application behavior for the following related scenarios:

    • To implement behavior when the application is closed, use the window.onUnload() event handler.
    • To implement behavior when the application is hidden, such as when another application is launched, create a listener for the visibilitychange event.
      Since 2015 devices, if the user has switched on the "Instant On" TV feature, switching off the TV causes the application to hide, triggering the visibility change event listener.
      For more information, see Monitoring Visibility Changes.

    #power key #visibility change
    #close application #hide application

  • A

    No. While an application is hidden, it is paused and cannot retrieve any information about the foreground application.

    #foreground application #hidden #paused
    #background application

  • A

    No. Retrieving the currently-active TV tuner is not supported, since it depends on the TV broadcaster.

    #tv tuner #cable tv #terrestrial tv
    #broadcast signal

  • A

    To retrieve the voice guide status:

    • On Tizen, check whether the voice guide is enabled using the getMenuValue() method with the TvInfoMenuKey.VOICE_GUIDE_KEY property:

      // Returns "true" if voice guide is enabled
    • On Samsung Legacy Platform, check whether the voice guide is enabled with the IsTTSEngineEnabled property:

      // Returns "true" if voice guide is enabled 
      webapis._plugin("RECOG", "IsTTSEngineEnabled")     

    #voice guide #samsung legacy platform
    #tts #text to speech

  • A

    Since 2013 TV models, to change the Samsung Apps TV region:

    1. Factory reset and restart the TV.
    2. On the Terms and Conditions page, click the following key sequence on the remote control: "Mute, Back, Volume Up, Channel Up, Mute"
    3. Select the region you want.

    #samsung apps tv #region change
    #app store #store region

  • A

    TV hardware is based on mobile technology, but for security reasons, the details are confidential.

    #hardware #cpu #processor

Extension Libraries

The following questions are related to implementing additional features with the available extension libraries.

Hosted Applications

The following questions are related to creating hosted applications.

  • A

    In a hosted or cloud-based application, the application code is downloaded from your Web server at runtime, or the application simply loads a Web page at a specific URL.

    Basically, hosted application is not allowed to submit due to security policy.
    It can be acceptable for some special cases only.

    You need to contact your Content Manager in advance.

    #cloud based application
    #dynamic web page #redirect application

  • A

    No. For security reasons, Tizen APIs are not supported in hosted applications.

    #tizen api
    #dynamic web page #cloud based application #redirect application

  • A

    Yes, but you must be a member of a partner group to create hosted applications.

    Simply convert your Web application to a hosted application, and submit an application update. You can also convert a hosted application to a Web application in the same way.

    #cloud based application #dynamic web page #migrate

  • A

    To load external scripts in your application, you must obtain permission from your Samsung Apps TV Seller Office Content Manager.

    Make sure you grant permission to access the external server in the application "config.xml" file, using the access element:

    <access origin="<SERVER_URL>" subdomains="true"></access>

    If your application needs to download content from multiple domains, in the "config.xml" file, define them in the tizen:allow-origin element.

    #external script
    #external js #dynamically loaded script

  • A

    Yes. Make sure you grant permission to access the external server in the application "config.xml" file, using the access element:

    <access origin="<SERVER_URL>" subdomains="true"></access>

    #external css #config xml
    #dynamically loaded css

  • A

    Make sure your Content Security Policy header does not use the unsafe-inline or unsafe-eval policies. For security reasons, they must not be used.

    #content security policy #csp #unsafe inline #unsafe eval #error


The following questions are related to implementing multimedia playback features.

Multimedia DRM

The following questions are related to implementing playback for media protected by digital rights management (DRM) technology.

Multimedia Streaming

The following questions are related to streaming media in applications.

Networking and Connectivity

The following questions are related to implementing networking and connectivity features.


The following questions are related to application privileges.

Samsung Legacy Platform

The following questions are related to developing applications for Samsung Legacy Platform.


The following questions are related to implementing security protocols in TV applications.

Smart Hub Preview

The following questions are related to implementing the Smart Hub Preview feature.

  • A

    Smart Hub Preview is a feature for Samsung Smart TVs that allows you to show content when the user hovers over your application icon in the launcher. The user can click the preview tile to open the content directly within the application. You can use the preview to promote new or personalized content to the user. For more information, see Smart Hub Preview.

    #preview #launcher #personalized content

  • A

    Make sure your JSON file URL and the defined tile image URLs are valid. Invalid tile image URLs can cause unexpected Smart Hub Preview behavior.

    #tile image #preview tile

  • A

    Smart Hub Preview is supported since 2016 TV models. It is also supported on the TV emulator since Tizen TV Extension 2.3.1.

    #tv model #emulator
    #feature support

  • A

    When implementing a personal preview, the background service application is required. While the foreground application performs the main application tasks, such as showing content, the background service application serves information to show in the preview. For more information on implementing a personal preview, including the background service application, see Implementing Personal Preview.

    #personal preview #background service application

  • A

    Smart Hub Preview tile images must be at least 250 px tall, with an aspect ratio of 16:9, 4:3, 1:1, or 2:3. Larger images are reduced to fit the specified aspect ratio. For more information, see Tile Element Specifications.

    #tile #size #image #aspect ratio

  • A

    Since languages can have different display character widths, there is no defined text length limit. However, long titles or subtitles can cause unintended Smart Hub Preview behavior.

    #section title #tile title #tile subtitle
    #title length

  • A

    The title and subtitle are only shown when the tile has focus. If you want to show text on the tile image even when it does not have focus, you can implement the text in the tile image itself.

    #tile title #tile subtitle

  • A

    You can define the JSON file as either "text/plain" or "application/json" type.

    #json file #media type
    #mime type #content type

  • A

    By default, the preview content is updated every 10 minutes and whenever the TV is switched on.

    You can also define a specific update time with the expires property, and define a new update time in the updated feed. The minimum time between updates is 10 minutes. After the feed updates at the defined time, if no new expires property is specified, the preview content is updated every 10 minutes.

    #feed update #update interval
    #refresh interval

  • A

    To show different content on Smart Hub Preview for specific model groups, such as 4K UHD video content on UHD TVs, you can implement a public preview. Create a separate application version that shows preview content from a different JSON file URL, and submit it for the applicable model groups.

    Alternatively, you can implement a personal preview, which allows you to customize the preview content for the user. Use the ProductInfo API to retrieve the model information from the TV, and use the background service application to serve content based on the model information retrieved.

    #public preview #private preview #model group #4k #uhd #productinfo api

  • A

    If the application is installed from a USB removable drive on a 2017 or later TV model, Smart Hub Preview does not work. This is a known limitation.

    #install #usb #missing tile #testing

  • A

    The preview content is updated in the following scenarios:

    • When the application is added to the launcher.
    • When the TV is switched on, after being fully powered off.
    • Every 10 minutes.
    • For a public preview, at the time defined by the expires parameter in the JSON file. The expires parameter value must be a time no more than 1 week into the future.
    • For a private preview, at a frequency defined by the background service application, based on the timestamp of the current JSON content. You can store the JSON content and timestamp in local storage using the Filesystem API.

    To implement preview content updates:

    • For a public preview, you must request the JSON file from the external URL defined in the use.preview metadata key of the config.xml file.
      If the public preview does not refresh properly:
      • Make sure that the JSON data received is valid.
      • Check that the expires parameter is correctly defined.
    • For a private preview, you must launch the background service application as a node module, and trigger the ON-START() and onRequest() event handlers.
      If the private preview does not refresh properly:
      • Make sure the background service application is running without errors.
      • If the background service application encounters an issue and must close, check that it is terminated properly using the getCurrentApplication().exit() method. If the background service application is not properly terminated, it cannot be relaunched at the next 10 minute interval.

    #background service application #application api #private preview #public preview

  • A

    Before launching the background service application, make sure the TV supports it:


    When you use the launchControl() method to launch a background service application on a TV that does not support service applications, it causes unexpected behavior in the foreground application, such as missing images and corrupted video playback.

    #background service application #launchcontrol #missing image
    #feature support

Specifications and Feature Support

The following questions are related to the specifications for and the features supported by Samsung Smart TVs.

Third-party Features

The following questions are related to features provided by third parties, such as Google or YouTube.

Tizen Studio

The following questions are related to developing applications with the Tizen Studio.

  • A

    If you are unable to test your application on your TV through the Tizen Studio, try the following actions:

    • In the Tizen Studio Package Manager, make sure the Samsung TV Extension is installed.
    • Create a new certificate profile, making sure you select the distributor certificate privilege level you need, then build the project with the new certificate profile.
    • Make sure installing your application on the device is allowed. In the Tizen Studio Device Manager, right-click on a folder of the connected device filesystem and select "Permit to install applications" in the context menu.
    • Export and reimport the project to the Tizen Studio:
      1. In the Tizen Studio, build your project as a signed ".wgt" package.
      2. Import the ".wgt" package as a new Tizen project:
        1. Since importing a project does not allow you to change the project name, rename the original project.
        2. In the Tizen Studio menu, select "File > Import > Tizen > Tizen project".
        3. Select "Select archive file" and navigate to the ".wgt" package.
        4. Select the target TV platform, and click "Finish".
      3. Launch the application on the TV from the new project.

    #troubleshooting #tv device

  • A

    All applications must be signed with valid certificates before they can be installed or run. The signature verifies the source of the application and makes sure it has not been tampered with since its publication. A certificate profile is a combination of the certificates used for signing, and it can be created using the Certificate Manager.

    #certificate profile #signing #certificate manager

  • A

    To work with the Samsung TV SDK, download and install the Tizen Studio, Samsung TV Extension, and Samsung Certificate Extension.

    #samsung tv sdk #samsung certificate extension #samsung tv extension
    #sdk access

  • A

    It is easy to create an application for a Samsung TV. For an overview of the TV Web application features and development process, from creating a project to publishing it on Samsung Apps TV, see Quick-start Guide.

    #quick start guide
    #getting started #beginner #application creation

  • A

    To avoid the warning, you can import the application package as a new project in the Tizen Studio:

    1. In the Tizen Studio menu, select "File > Import > Tizen > Tizen project".
    2. Select "Select archive file" and navigate to the ".wgt" package.
    3. Select your TV's platform version, and click "Finish".

      Since Tizen Studio 1.1.1, the Tizen Studio supports creating Tizen 3.0 and higher TV applications only. However, the "Platform not supported" warning does not affect application functionality when testing on TVs running older Tizen versions.

    #testing #unsupported platform #deprecated platform

  • A

    Make sure you are using the latest Tizen Studio version. For the Tizen Studio release notes and a list of known issues, see Tizen Studio Release Notes on the Tizen Developers Web site.

    #release note #known issue #troubleshooting

  • A

    To sign application packages with your author certificate, the certificate must be valid.

    To renew an existing author certificate, in the Tizen Studio Certificate Manager, create a new certificate profile with it. In the "Author Certificate" step, select the "Select an existing author certificate" option, and enter your existing author certificate and password.

    #author certificate #certificate profile #certificate manager
    #renew certificate #signature

  • A

    To import an existing author certificate to the Tizen Studio Certificate Manager, create a new certificate profile. In the "Author Certificate" step, select the "Select an existing author certificate" option, and enter your existing author certificate and password.

    #author certificate #certificate profile #certificate manager
    #import certificate #signature

  • A

    If you prefer a command line interface to the graphical Tizen Studio window, you can use the Tizen Studio Command Line Interface (CLI) tool throughout the development process.

    When testing your application, you can also use various SDB shell commands.

    #command line tool #command line interface #cli #sdb shell

  • A

    When you package an application with the Tizen Studio, all JavaScript code files in the "js" directory are validated. If the JavaScript code has been minified, it can cause significant delays in the validation process. However, JavaScript libraries in the "lib" directory are not validated. To avoid JavaScript validation delays, you can place the minified JavaScript code files in the "lib" directory.

    #js validation #javascript validation #application packaging #minification #javascript library

  • A

    Check that your environment variables are configured for Tizen Studio use. On your computer, make sure the "<TIZEN_STUDIO>\tools\ide\bin" directory is defined in the PATH environment variable.

    #wgt file #package #build #path #environment variable

  • A

    Yes, you can use CSS preprocessors, such as Sass and Less, as Eclipse plugins within the Tizen Studio. However, Samsung does not provide support for third-party tools.

    #css preprocessor #eclipse plugin #sass #less

User Interaction

The following questions are related to user interaction features provided by a keyboard, mouse, or pointer.

  • A

    To disable the pointer and mouse functionality in your application, make sure the "config.xml" file contains the following elements:

    <tizen:setting pointing-device-support='disable'/>
    <tizen:profile name="tv-samsung"/>

    For more information, see Mouse.

    #pointer #mouse #disable
    #air pointer #pointing device

  • A

    Even if your application does not support a keyboard, there are some hidden keys that work with a keyboard. The following hidden keys must be mapped to the remote control keys.

    Table 1. Hidden key mapping
    Hidden Key Remote Control Key Hidden Key Remote Control Key
    Esc Return F5 Smart Hub
    Number keys Channel number F6 Source
    Windows key Menu F7 Channel List
    Arrow keys Move focus (cursor) F8 Volume Mute
    Enter Enter F9 Volume Down
    F1 Color Key A F10 Volume Up
    F2 Color Key B F11 Channel Down
    F3 Color Key C F12 Channel Up
    F4 Color Key D Number pad input Channel number

    #key #mapping #remote control
    #hidden key #keyboard event

  • A

    No, it is not possible to disable the keyboard.

    Since some keyboard keys have the same code as the remote controls key, they cannot be disabled. For other keyboard keys, implement a default action to make sure the application does not respond when they are pressed. For more information, see Keyboard/IME.

    #disable #keyboard #key

  • A

    The Samsung policy requires that the "Exit" key allows the user to exit the application and return to the live broadcast channel immediately from anywhere within the application.

    However, there is no Samsung API method that you can use to manually implement this behavior for the "Exit" key. To follow the policy, unregister the "Exit" key and do not handle it in your application. The key's default behavior implements the policy.

    In contexts other than the "Exit" key click, you can close the application and all its content by calling the getCurrentApplication().exit() method. For example, a "Return" key click opens a popup with "Yes" and "No" buttons, and selecting the "Yes" button calls the getCurrentApplication().exit() method.


    Do not open a popup after the "Exit" key click. The "Exit" key click must immediately exit the application, and any other behavior causes your application to fail its certification checks.

    #exit key #broadcast channel #show channel
    #application exit #closing application

  • A

    To customize the IME to show the number pad only, in the input element, set the type attribute to number. This disables all the letter keys and prediction in the IME.


    On 2015 TV models, this works correctly. However, the 2016 and 2017 TV models do not show the IME correctly. The issue will be fixed in a future firmware release.

    For more information on the IME, see Keyboard/IME.

    #IME #customize #keyboard #number pad
    #number input type #num pad

  • A

    To block a key event, register the key:


    The registration blocks the key's default functionality.

    #block #key #register #event
    #disable #prevent

  • A

    If you register an event for a function key but do not add code to handle the event, the key no longer works. The default function of the key stops working when you register the key event in your application.


    Do not register keys that are supposed to be handled by the platform, and only register keys that the application uses.

    #smart hub #power #key
    #broken #not working

  • A

    Some Samsung TV remote control keys have separate functionalities for normal and long presses, while others only recognize a normal key press. For information on which keys support long presses, see Remote Control.

    #long press #key #remote control
    #different key function #smart remote

  • A

    No, it is not possible to make the remote control special keys, such as the color or playback control keys, work in the Web browser. The Web browser does not have access to the Samsung Product and Tizen APIs.

    #remote control #special key #color key #playback control key #web browser
    #key mapping

  • A

    Yes. To set the maximum length for an input element, define the length in characters using the maxlength attribute.

    #html #input element #maximum length
    #text entry

  • A

    From your application home screen, you can implement the "Return" key to terminate or hide the application. For more information, see Terminating Applications.

    #return key #hide #terminate #policy
    #key mapping #exit

  • A

    The Samsung IME supports the standard keyboard characters, such as upper and lower case letters, numbers, punctuation, and symbols.

    #input method editor #ime #character #number #letter #punctuation #symbol #keyboard

  • A

    Each remote control key has a key name and corresponding numerical code value. Since keyCode values can differ depending on the TV model and platform version, it is recommended to implement key input using the key names whenever possible.

    If you implement keyboard input, the keyboard keys also have key codes.

    #remote control #key name #key code #keyboard
    #key mapping

  • A

    The IME does not display correctly in the emulator. This is a known issue.

    #input method editor #ime #emulator
    #keyboard #tv device

  • A

    The getCurrentApplication().exit() method of the Application API closes the application and all its content. For example, a "Return" key click opens a popup with "Yes" and "No" buttons, and selecting the "Yes" button calls the getCurrentApplication().exit() method. For more information, see Terminating Applications.

    Use the getCurrentApplication().hide() method when you do not want to close the application, but only hide it in the background. For more information, see Multitasking.

    #return key #hide #exit #terminate #multitasking #application api

  • A

    To avoid issues with keyboard key presses preventing HTML input elements from working properly, do not implement the preventDefault() method within your keydown and keypress event listeners.

    #html #input element #keyboard #preventdefault #keydown #keypress
    #no input

  • A

    The pointer is a feature on the remote control included with 2015 Samsung Smart TV models. The feature allows the user to move the mouse cursor by gesturing with the remote control. To enable pointer support in your application, implement mouse support.

    #pointer #gesture #remote control #mouse
    #air pointer

  • A

    No. Since keyCode values for keyboard keys can differ depending on the TV model and platform version, event handling for specific letter keys is not supported. For more information on handling keyboard and IME input, see Keyboard/IME.

    #ime #input method editor #keyboard #keycode #letter key
    #key event

Other Features

The following questions are related to various TV application features.