In a multi language solution, you can make sure that an item is only rendered on a specific language version of the website, if the item has a version in that particular language.
In Sitecore versions prior to 8.1, default behavior returned empty untranslated items if the requested item language version did not exist. This usually manifested in seeing a lot of '$name' macros or empty pages instead of a real content or Item Not Found page. Handling this properly required custom code.
Starting from Sitecore 8.1 there is an Enforce Version Presence feature configurable on the website and on the relevant item or template Standard Values level which allows to achieve the aforementioned behavior using the below configuration.
When you enable Enforce Version Presence for an item, an actual version of the item in the relevant language must be available for it (in other words, the item has to be translated) to be returned from the API and displayed on the website. If an item with no versions in the context language is requested by URL, Sitecore will redirect to the Item Not Found page if this feature is enabled.
By default, the Enforce Version Presence feature is disabled. You should enable the feature on the relevant websites and on the relevant items or template Standard Values.
Follow these steps to enable version presence enforcement on your Sitecore instance:
<sites> <site name="website"> <patch:attribute name="enforceVersionPresence">true</patch:attribute> </site> </sites>
Notes
* For single site installations, website site is sufficient. It is not recommended to enable this feature for the shell site or any other system sites, as the primary use case for this feature is content delivery.
** Step 1 applies to all Sitecore instances, including Content Delivery, where the Enforce Version Presence needs to be enabled.