Platform.sh supports a number of profiling services for optimizing your code. These are third party services and may have their own associated cost. Also note that these are often language-specific and may not be available for all languages.
Platform.sh supports Blackfire.io. Blackfire is a PHP profiler and automated performance testing tool that can be used in the development Integration, Staging, and Production environments.
Platform.sh supports New Relic APM for profiling PHP applications. These instructions do not apply to other languages.
Platform.sh supports Tideways APM for PHP. This functionality is only available on PHP 7.0 and later.